<!doctype html>
<html style='font-size:16px !important'>
<head>
<meta charset='UTF-8'><meta name='viewport' content='width=device-width initial-scale=1'>

<link href='https://fonts.loli.net/css?family=Open+Sans:400italic,700italic,700,400&subset=latin,latin-ext' rel='stylesheet' type='text/css' /><style type='text/css'>html {overflow-x: initial !important;}:root { --mermaid-theme: default; --mermaid-sequence-numbers: off; --mermaid-flowchart-curve: linear; --mermaid--gantt-left-padding: 75; --sequence-theme: simple; }


:root { --bg-color:#ffffff; --text-color:#333333; --select-text-bg-color:#B5D6FC; --select-text-font-color:auto; --monospace:"Lucida Console",Consolas,"Courier",monospace; --title-bar-height:20px; }
.mac-os-11 { --title-bar-height:28px; }
html { font-size: 14px; background-color: var(--bg-color); color: var(--text-color); font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; -webkit-font-smoothing: antialiased; }
body { margin: 0px; padding: 0px; height: auto; inset: 0px; font-size: 1rem; line-height: 1.42857; overflow-x: hidden; background: inherit; tab-size: 4; }
iframe { margin: auto; }
a.url { word-break: break-all; }
a:active, a:hover { outline: 0px; }
.in-text-selection, ::selection { text-shadow: none; background: var(--select-text-bg-color); color: var(--select-text-font-color); }
#write { margin: 0px auto; height: auto; width: inherit; word-break: normal; overflow-wrap: break-word; position: relative; white-space: normal; overflow-x: visible; padding-top: 36px; }
#write.first-line-indent p { text-indent: 2em; }
#write.first-line-indent li p, #write.first-line-indent p * { text-indent: 0px; }
#write.first-line-indent li { margin-left: 2em; }
.for-image #write { padding-left: 8px; padding-right: 8px; }
body.typora-export { padding-left: 30px; padding-right: 30px; }
.typora-export .footnote-line, .typora-export li, .typora-export p { white-space: pre-wrap; }
.typora-export .task-list-item input { pointer-events: none; }
@media screen and (max-width: 500px) {
  body.typora-export { padding-left: 0px; padding-right: 0px; }
  #write { padding-left: 20px; padding-right: 20px; }
  .CodeMirror-sizer { margin-left: 0px !important; }
  .CodeMirror-gutters { display: none !important; }
}
#write li > figure:last-child { margin-bottom: 0.5rem; }
#write ol, #write ul { position: relative; }
img { max-width: 100%; vertical-align: middle; image-orientation: from-image; }
button, input, select, textarea { color: inherit; font: inherit; }
input[type="checkbox"], input[type="radio"] { line-height: normal; padding: 0px; }
*, ::after, ::before { box-sizing: border-box; }
#write h1, #write h2, #write h3, #write h4, #write h5, #write h6, #write p, #write pre { width: inherit; }
#write h1, #write h2, #write h3, #write h4, #write h5, #write h6, #write p { position: relative; }
p { line-height: inherit; }
h1, h2, h3, h4, h5, h6 { break-after: avoid-page; break-inside: avoid; orphans: 4; }
p { orphans: 4; }
h1 { font-size: 2rem; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.6rem; }
h4 { font-size: 1.4rem; }
h5 { font-size: 1.2rem; }
h6 { font-size: 1rem; }
.md-math-block, .md-rawblock, h1, h2, h3, h4, h5, h6, p { margin-top: 1rem; margin-bottom: 1rem; }
.hidden { display: none; }
.md-blockmeta { color: rgb(204, 204, 204); font-weight: 700; font-style: italic; }
a { cursor: pointer; }
sup.md-footnote { padding: 2px 4px; background-color: rgba(238, 238, 238, 0.7); color: rgb(85, 85, 85); border-radius: 4px; cursor: pointer; }
sup.md-footnote a, sup.md-footnote a:hover { color: inherit; text-transform: inherit; text-decoration: inherit; }
#write input[type="checkbox"] { cursor: pointer; width: inherit; height: inherit; }
figure { overflow-x: auto; margin: 1.2em 0px; max-width: calc(100% + 16px); padding: 0px; }
figure > table { margin: 0px; }
tr { break-inside: avoid; break-after: auto; }
thead { display: table-header-group; }
table { border-collapse: collapse; border-spacing: 0px; width: 100%; overflow: auto; break-inside: auto; text-align: left; }
table.md-table td { min-width: 32px; }
.CodeMirror-gutters { border-right: 0px; background-color: inherit; }
.CodeMirror-linenumber { user-select: none; }
.CodeMirror { text-align: left; }
.CodeMirror-placeholder { opacity: 0.3; }
.CodeMirror pre { padding: 0px 4px; }
.CodeMirror-lines { padding: 0px; }
div.hr:focus { cursor: none; }
#write pre { white-space: pre-wrap; }
#write.fences-no-line-wrapping pre { white-space: pre; }
#write pre.ty-contain-cm { white-space: normal; }
.CodeMirror-gutters { margin-right: 4px; }
.md-fences { font-size: 0.9rem; display: block; break-inside: avoid; text-align: left; overflow: visible; white-space: pre; background: inherit; position: relative !important; }
.md-fences-adv-panel { width: 100%; margin-top: 10px; text-align: center; padding-top: 0px; padding-bottom: 8px; overflow-x: auto; }
#write .md-fences.mock-cm { white-space: pre-wrap; }
.md-fences.md-fences-with-lineno { padding-left: 0px; }
#write.fences-no-line-wrapping .md-fences.mock-cm { white-space: pre; overflow-x: auto; }
.md-fences.mock-cm.md-fences-with-lineno { padding-left: 8px; }
.CodeMirror-line, twitterwidget { break-inside: avoid; }
.footnotes { opacity: 0.8; font-size: 0.9rem; margin-top: 1em; margin-bottom: 1em; }
.footnotes + .footnotes { margin-top: 0px; }
.md-reset { margin: 0px; padding: 0px; border: 0px; outline: 0px; vertical-align: top; background: 0px 0px; text-decoration: none; text-shadow: none; float: none; position: static; width: auto; height: auto; white-space: nowrap; cursor: inherit; -webkit-tap-highlight-color: transparent; line-height: normal; font-weight: 400; text-align: left; box-sizing: content-box; direction: ltr; }
li div { padding-top: 0px; }
blockquote { margin: 1rem 0px; }
li .mathjax-block, li p { margin: 0.5rem 0px; }
li blockquote { margin: 1rem 0px; }
li { margin: 0px; position: relative; }
blockquote > :last-child { margin-bottom: 0px; }
blockquote > :first-child, li > :first-child { margin-top: 0px; }
.footnotes-area { color: rgb(136, 136, 136); margin-top: 0.714rem; padding-bottom: 0.143rem; white-space: normal; }
#write .footnote-line { white-space: pre-wrap; }
@media print {
  body, html { border: 1px solid transparent; height: 99%; break-after: avoid; break-before: avoid; font-variant-ligatures: no-common-ligatures; }
  #write { margin-top: 0px; padding-top: 0px; border-color: transparent !important; }
  .typora-export * { -webkit-print-color-adjust: exact; }
  .typora-export #write { break-after: avoid; }
  .typora-export #write::after { height: 0px; }
  .is-mac table { break-inside: avoid; }
  .typora-export-show-outline .typora-export-sidebar { display: none; }
}
.footnote-line { margin-top: 0.714em; font-size: 0.7em; }
a img, img a { cursor: pointer; }
pre.md-meta-block { font-size: 0.8rem; min-height: 0.8rem; white-space: pre-wrap; background: rgb(204, 204, 204); display: block; overflow-x: hidden; }
p > .md-image:only-child:not(.md-img-error) img, p > img:only-child { display: block; margin: auto; }
#write.first-line-indent p > .md-image:only-child:not(.md-img-error) img { left: -2em; position: relative; }
p > .md-image:only-child { display: inline-block; width: 100%; }
#write .MathJax_Display { margin: 0.8em 0px 0px; }
.md-math-block { width: 100%; }
.md-math-block:not(:empty)::after { display: none; }
.MathJax_ref { fill: currentcolor; }
[contenteditable="true"]:active, [contenteditable="true"]:focus, [contenteditable="false"]:active, [contenteditable="false"]:focus { outline: 0px; box-shadow: none; }
.md-task-list-item { position: relative; list-style-type: none; }
.task-list-item.md-task-list-item { padding-left: 0px; }
.md-task-list-item > input { position: absolute; top: 0px; left: 0px; margin-left: -1.2em; margin-top: calc(1em - 10px); border: none; }
.math { font-size: 1rem; }
.md-toc { min-height: 3.58rem; position: relative; font-size: 0.9rem; border-radius: 10px; }
.md-toc-content { position: relative; margin-left: 0px; }
.md-toc-content::after, .md-toc::after { display: none; }
.md-toc-item { display: block; color: rgb(65, 131, 196); }
.md-toc-item a { text-decoration: none; }
.md-toc-inner:hover { text-decoration: underline; }
.md-toc-inner { display: inline-block; cursor: pointer; }
.md-toc-h1 .md-toc-inner { margin-left: 0px; font-weight: 700; }
.md-toc-h2 .md-toc-inner { margin-left: 2em; }
.md-toc-h3 .md-toc-inner { margin-left: 4em; }
.md-toc-h4 .md-toc-inner { margin-left: 6em; }
.md-toc-h5 .md-toc-inner { margin-left: 8em; }
.md-toc-h6 .md-toc-inner { margin-left: 10em; }
@media screen and (max-width: 48em) {
  .md-toc-h3 .md-toc-inner { margin-left: 3.5em; }
  .md-toc-h4 .md-toc-inner { margin-left: 5em; }
  .md-toc-h5 .md-toc-inner { margin-left: 6.5em; }
  .md-toc-h6 .md-toc-inner { margin-left: 8em; }
}
a.md-toc-inner { font-size: inherit; font-style: inherit; font-weight: inherit; line-height: inherit; }
.footnote-line a:not(.reversefootnote) { color: inherit; }
.md-attr { display: none; }
.md-fn-count::after { content: "."; }
code, pre, samp, tt { font-family: var(--monospace); }
kbd { margin: 0px 0.1em; padding: 0.1em 0.6em; font-size: 0.8em; color: rgb(36, 39, 41); background: rgb(255, 255, 255); border: 1px solid rgb(173, 179, 185); border-radius: 3px; box-shadow: rgba(12, 13, 14, 0.2) 0px 1px 0px, rgb(255, 255, 255) 0px 0px 0px 2px inset; white-space: nowrap; vertical-align: middle; }
.md-comment { color: rgb(162, 127, 3); opacity: 0.6; font-family: var(--monospace); }
code { text-align: left; vertical-align: initial; }
a.md-print-anchor { white-space: pre !important; border-width: initial !important; border-style: none !important; border-color: initial !important; display: inline-block !important; position: absolute !important; width: 1px !important; right: 0px !important; outline: 0px !important; background: 0px 0px !important; text-decoration: initial !important; text-shadow: initial !important; }
.os-windows.monocolor-emoji .md-emoji { font-family: "Segoe UI Symbol", sans-serif; }
.md-diagram-panel > svg { max-width: 100%; }
[lang="flow"] svg, [lang="mermaid"] svg { max-width: 100%; height: auto; }
[lang="mermaid"] .node text { font-size: 1rem; }
table tr th { border-bottom: 0px; }
video { max-width: 100%; display: block; margin: 0px auto; }
iframe { max-width: 100%; width: 100%; border: none; }
.highlight td, .highlight tr { border: 0px; }
mark { background: rgb(255, 255, 0); color: rgb(0, 0, 0); }
.md-html-inline .md-plain, .md-html-inline strong, mark .md-inline-math, mark strong { color: inherit; }
.md-expand mark .md-meta { opacity: 0.3 !important; }
mark .md-meta { color: rgb(0, 0, 0); }
@media print {
  .typora-export h1, .typora-export h2, .typora-export h3, .typora-export h4, .typora-export h5, .typora-export h6 { break-inside: avoid; }
}
.md-diagram-panel .messageText { stroke: none !important; }
.md-diagram-panel .start-state { fill: var(--node-fill); }
.md-diagram-panel .edgeLabel rect { opacity: 1 !important; }
.md-fences.md-fences-math { font-size: 1em; }
.md-fences-advanced:not(.md-focus) { padding: 0px; white-space: nowrap; border: 0px; }
.md-fences-advanced:not(.md-focus) { background: inherit; }
.typora-export-show-outline .typora-export-content { max-width: 1440px; margin: auto; display: flex; flex-direction: row; }
.typora-export-sidebar { width: 300px; font-size: 0.8rem; margin-top: 80px; margin-right: 18px; }
.typora-export-show-outline #write { --webkit-flex:2; flex: 2 1 0%; }
.typora-export-sidebar .outline-content { position: fixed; top: 0px; max-height: 100%; overflow: hidden auto; padding-bottom: 30px; padding-top: 60px; width: 300px; }
@media screen and (max-width: 1024px) {
  .typora-export-sidebar, .typora-export-sidebar .outline-content { width: 240px; }
}
@media screen and (max-width: 800px) {
  .typora-export-sidebar { display: none; }
}
.outline-content li, .outline-content ul { margin-left: 0px; margin-right: 0px; padding-left: 0px; padding-right: 0px; list-style: none; }
.outline-content ul { margin-top: 0px; margin-bottom: 0px; }
.outline-content strong { font-weight: 400; }
.outline-expander { width: 1rem; height: 1.42857rem; position: relative; display: table-cell; vertical-align: middle; cursor: pointer; padding-left: 4px; }
.outline-expander::before { content: ""; position: relative; font-family: Ionicons; display: inline-block; font-size: 8px; vertical-align: middle; }
.outline-item { padding-top: 3px; padding-bottom: 3px; cursor: pointer; }
.outline-expander:hover::before { content: ""; }
.outline-h1 > .outline-item { padding-left: 0px; }
.outline-h2 > .outline-item { padding-left: 1em; }
.outline-h3 > .outline-item { padding-left: 2em; }
.outline-h4 > .outline-item { padding-left: 3em; }
.outline-h5 > .outline-item { padding-left: 4em; }
.outline-h6 > .outline-item { padding-left: 5em; }
.outline-label { cursor: pointer; display: table-cell; vertical-align: middle; text-decoration: none; color: inherit; }
.outline-label:hover { text-decoration: underline; }
.outline-item:hover { border-color: rgb(245, 245, 245); background-color: var(--item-hover-bg-color); }
.outline-item:hover { margin-left: -28px; margin-right: -28px; border-left: 28px solid transparent; border-right: 28px solid transparent; }
.outline-item-single .outline-expander::before, .outline-item-single .outline-expander:hover::before { display: none; }
.outline-item-open > .outline-item > .outline-expander::before { content: ""; }
.outline-children { display: none; }
.info-panel-tab-wrapper { display: none; }
.outline-item-open > .outline-children { display: block; }
.typora-export .outline-item { padding-top: 1px; padding-bottom: 1px; }
.typora-export .outline-item:hover { margin-right: -8px; border-right: 8px solid transparent; }
.typora-export .outline-expander::before { content: "+"; font-family: inherit; top: -1px; }
.typora-export .outline-expander:hover::before, .typora-export .outline-item-open > .outline-item > .outline-expander::before { content: "−"; }
.typora-export-collapse-outline .outline-children { display: none; }
.typora-export-collapse-outline .outline-item-open > .outline-children, .typora-export-no-collapse-outline .outline-children { display: block; }
.typora-export-no-collapse-outline .outline-expander::before { content: "" !important; }
.typora-export-show-outline .outline-item-active > .outline-item .outline-label { font-weight: 700; }
.md-inline-math-container mjx-container { zoom: 0.95; }


.CodeMirror { height: auto; }
.CodeMirror.cm-s-inner { background: inherit; }
.CodeMirror-scroll { overflow: auto hidden; z-index: 3; }
.CodeMirror-gutter-filler, .CodeMirror-scrollbar-filler { background-color: rgb(255, 255, 255); }
.CodeMirror-gutters { border-right: 1px solid rgb(221, 221, 221); background: inherit; white-space: nowrap; }
.CodeMirror-linenumber { padding: 0px 3px 0px 5px; text-align: right; color: rgb(153, 153, 153); }
.cm-s-inner .cm-keyword { color: rgb(119, 0, 136); }
.cm-s-inner .cm-atom, .cm-s-inner.cm-atom { color: rgb(34, 17, 153); }
.cm-s-inner .cm-number { color: rgb(17, 102, 68); }
.cm-s-inner .cm-def { color: rgb(0, 0, 255); }
.cm-s-inner .cm-variable { color: rgb(0, 0, 0); }
.cm-s-inner .cm-variable-2 { color: rgb(0, 85, 170); }
.cm-s-inner .cm-variable-3 { color: rgb(0, 136, 85); }
.cm-s-inner .cm-string { color: rgb(170, 17, 17); }
.cm-s-inner .cm-property { color: rgb(0, 0, 0); }
.cm-s-inner .cm-operator { color: rgb(152, 26, 26); }
.cm-s-inner .cm-comment, .cm-s-inner.cm-comment { color: rgb(170, 85, 0); }
.cm-s-inner .cm-string-2 { color: rgb(255, 85, 0); }
.cm-s-inner .cm-meta { color: rgb(85, 85, 85); }
.cm-s-inner .cm-qualifier { color: rgb(85, 85, 85); }
.cm-s-inner .cm-builtin { color: rgb(51, 0, 170); }
.cm-s-inner .cm-bracket { color: rgb(153, 153, 119); }
.cm-s-inner .cm-tag { color: rgb(17, 119, 0); }
.cm-s-inner .cm-attribute { color: rgb(0, 0, 204); }
.cm-s-inner .cm-header, .cm-s-inner.cm-header { color: rgb(0, 0, 255); }
.cm-s-inner .cm-quote, .cm-s-inner.cm-quote { color: rgb(0, 153, 0); }
.cm-s-inner .cm-hr, .cm-s-inner.cm-hr { color: rgb(153, 153, 153); }
.cm-s-inner .cm-link, .cm-s-inner.cm-link { color: rgb(0, 0, 204); }
.cm-negative { color: rgb(221, 68, 68); }
.cm-positive { color: rgb(34, 153, 34); }
.cm-header, .cm-strong { font-weight: 700; }
.cm-del { text-decoration: line-through; }
.cm-em { font-style: italic; }
.cm-link { text-decoration: underline; }
.cm-error { color: red; }
.cm-invalidchar { color: red; }
.cm-constant { color: rgb(38, 139, 210); }
.cm-defined { color: rgb(181, 137, 0); }
div.CodeMirror span.CodeMirror-matchingbracket { color: rgb(0, 255, 0); }
div.CodeMirror span.CodeMirror-nonmatchingbracket { color: rgb(255, 34, 34); }
.cm-s-inner .CodeMirror-activeline-background { background: inherit; }
.CodeMirror { position: relative; overflow: hidden; }
.CodeMirror-scroll { height: 100%; outline: 0px; position: relative; box-sizing: content-box; background: inherit; }
.CodeMirror-sizer { position: relative; }
.CodeMirror-gutter-filler, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-vscrollbar { position: absolute; z-index: 6; display: none; outline: 0px; }
.CodeMirror-vscrollbar { right: 0px; top: 0px; overflow: hidden; }
.CodeMirror-hscrollbar { bottom: 0px; left: 0px; overflow: auto hidden; }
.CodeMirror-scrollbar-filler { right: 0px; bottom: 0px; }
.CodeMirror-gutter-filler { left: 0px; bottom: 0px; }
.CodeMirror-gutters { position: absolute; left: 0px; top: 0px; padding-bottom: 10px; z-index: 3; overflow-y: hidden; }
.CodeMirror-gutter { white-space: normal; height: 100%; box-sizing: content-box; padding-bottom: 30px; margin-bottom: -32px; display: inline-block; }
.CodeMirror-gutter-wrapper { position: absolute; z-index: 4; background: 0px 0px !important; border: none !important; }
.CodeMirror-gutter-background { position: absolute; top: 0px; bottom: 0px; z-index: 4; }
.CodeMirror-gutter-elt { position: absolute; cursor: default; z-index: 4; }
.CodeMirror-lines { cursor: text; }
.CodeMirror pre { border-radius: 0px; border-width: 0px; background: 0px 0px; font-family: inherit; font-size: inherit; margin: 0px; white-space: pre; overflow-wrap: normal; color: inherit; z-index: 2; position: relative; overflow: visible; }
.CodeMirror-wrap pre { overflow-wrap: break-word; white-space: pre-wrap; word-break: normal; }
.CodeMirror-code pre { border-right: 30px solid transparent; width: fit-content; }
.CodeMirror-wrap .CodeMirror-code pre { border-right: none; width: auto; }
.CodeMirror-linebackground { position: absolute; inset: 0px; z-index: 0; }
.CodeMirror-linewidget { position: relative; z-index: 2; overflow: auto; }
.CodeMirror-wrap .CodeMirror-scroll { overflow-x: hidden; }
.CodeMirror-measure { position: absolute; width: 100%; height: 0px; overflow: hidden; visibility: hidden; }
.CodeMirror-measure pre { position: static; }
.CodeMirror div.CodeMirror-cursor { position: absolute; visibility: hidden; border-right: none; width: 0px; }
.CodeMirror div.CodeMirror-cursor { visibility: hidden; }
.CodeMirror-focused div.CodeMirror-cursor { visibility: inherit; }
.cm-searching { background: rgba(255, 255, 0, 0.4); }
span.cm-underlined { text-decoration: underline; }
span.cm-strikethrough { text-decoration: line-through; }
.cm-tw-syntaxerror { color: rgb(255, 255, 255); background-color: rgb(153, 0, 0); }
.cm-tw-deleted { text-decoration: line-through; }
.cm-tw-header5 { font-weight: 700; }
.cm-tw-listitem:first-child { padding-left: 10px; }
.cm-tw-box { border-style: solid; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-color: inherit; border-top-width: 0px !important; }
.cm-tw-underline { text-decoration: underline; }
@media print {
  .CodeMirror div.CodeMirror-cursor { visibility: hidden; }
}


:root {
    --side-bar-bg-color: #fafafa;
    --control-text-color: #777;
}

@include-when-export url(https://fonts.loli.net/css?family=Open+Sans:400italic,700italic,700,400&subset=latin,latin-ext);

/* open-sans-regular - latin-ext_latin */
  /* open-sans-italic - latin-ext_latin */
    /* open-sans-700 - latin-ext_latin */
    /* open-sans-700italic - latin-ext_latin */
  html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: "Open Sans","Clear Sans", "Helvetica Neue", Helvetica, Arial, 'Segoe UI Emoji', sans-serif;
    color: rgb(51, 51, 51);
    line-height: 1.6;
}

#write {
    max-width: 860px;
  	margin: 0 auto;
  	padding: 30px;
    padding-bottom: 100px;
}

@media only screen and (min-width: 1400px) {
	#write {
		max-width: 1024px;
	}
}

@media only screen and (min-width: 1800px) {
	#write {
		max-width: 1200px;
	}
}

#write > ul:first-child,
#write > ol:first-child{
    margin-top: 30px;
}

a {
    color: #4183C4;
}
h1,
h2,
h3,
h4,
h5,
h6 {
    position: relative;
    margin-top: 1rem;
    margin-bottom: 1rem;
    font-weight: bold;
    line-height: 1.4;
    cursor: text;
}
h1:hover a.anchor,
h2:hover a.anchor,
h3:hover a.anchor,
h4:hover a.anchor,
h5:hover a.anchor,
h6:hover a.anchor {
    text-decoration: none;
}
h1 tt,
h1 code {
    font-size: inherit;
}
h2 tt,
h2 code {
    font-size: inherit;
}
h3 tt,
h3 code {
    font-size: inherit;
}
h4 tt,
h4 code {
    font-size: inherit;
}
h5 tt,
h5 code {
    font-size: inherit;
}
h6 tt,
h6 code {
    font-size: inherit;
}
h1 {
    font-size: 2.25em;
    line-height: 1.2;
    border-bottom: 1px solid #eee;
}
h2 {
    font-size: 1.75em;
    line-height: 1.225;
    border-bottom: 1px solid #eee;
}

/*@media print {
    .typora-export h1,
    .typora-export h2 {
        border-bottom: none;
        padding-bottom: initial;
    }

    .typora-export h1::after,
    .typora-export h2::after {
        content: "";
        display: block;
        height: 100px;
        margin-top: -96px;
        border-top: 1px solid #eee;
    }
}*/

h3 {
    font-size: 1.5em;
    line-height: 1.43;
}
h4 {
    font-size: 1.25em;
}
h5 {
    font-size: 1em;
}
h6 {
   font-size: 1em;
    color: #777;
}
p,
blockquote,
ul,
ol,
dl,
table{
    margin: 0.8em 0;
}
li>ol,
li>ul {
    margin: 0 0;
}
hr {
    height: 2px;
    padding: 0;
    margin: 16px 0;
    background-color: #e7e7e7;
    border: 0 none;
    overflow: hidden;
    box-sizing: content-box;
}

li p.first {
    display: inline-block;
}
ul,
ol {
    padding-left: 30px;
}
ul:first-child,
ol:first-child {
    margin-top: 0;
}
ul:last-child,
ol:last-child {
    margin-bottom: 0;
}
blockquote {
    border-left: 4px solid #dfe2e5;
    padding: 0 15px;
    color: #777777;
}
blockquote blockquote {
    padding-right: 0;
}
table {
    padding: 0;
    word-break: initial;
}
table tr {
    border: 1px solid #dfe2e5;
    margin: 0;
    padding: 0;
}
table tr:nth-child(2n),
thead {
    background-color: #f8f8f8;
}
table th {
    font-weight: bold;
    border: 1px solid #dfe2e5;
    border-bottom: 0;
    margin: 0;
    padding: 6px 13px;
}
table td {
    border: 1px solid #dfe2e5;
    margin: 0;
    padding: 6px 13px;
}
table th:first-child,
table td:first-child {
    margin-top: 0;
}
table th:last-child,
table td:last-child {
    margin-bottom: 0;
}

.CodeMirror-lines {
    padding-left: 4px;
}

.code-tooltip {
    box-shadow: 0 1px 1px 0 rgba(0,28,36,.3);
    border-top: 1px solid #eef2f2;
}

.md-fences,
code,
tt {
    border: 1px solid #e7eaed;
    background-color: #f8f8f8;
    border-radius: 3px;
    padding: 0;
    padding: 2px 4px 0px 4px;
    font-size: 0.9em;
}

code {
    background-color: #f3f4f4;
    padding: 0 2px 0 2px;
}

.md-fences {
    margin-bottom: 15px;
    margin-top: 15px;
    padding-top: 8px;
    padding-bottom: 6px;
}


.md-task-list-item > input {
  margin-left: -1.3em;
}

@media print {
    html {
        font-size: 13px;
    }
    table,
    pre {
        page-break-inside: avoid;
    }
    pre {
        word-wrap: break-word;
    }
}

.md-fences {
	background-color: #f8f8f8;
}
#write pre.md-meta-block {
	padding: 1rem;
    font-size: 85%;
    line-height: 1.45;
    background-color: #f7f7f7;
    border: 0;
    border-radius: 3px;
    color: #777777;
    margin-top: 0 !important;
}

.mathjax-block>.code-tooltip {
	bottom: .375rem;
}

.md-mathjax-midline {
    background: #fafafa;
}

#write>h3.md-focus:before{
	left: -1.5625rem;
	top: .375rem;
}
#write>h4.md-focus:before{
	left: -1.5625rem;
	top: .285714286rem;
}
#write>h5.md-focus:before{
	left: -1.5625rem;
	top: .285714286rem;
}
#write>h6.md-focus:before{
	left: -1.5625rem;
	top: .285714286rem;
}
.md-image>.md-meta {
    /*border: 1px solid #ddd;*/
    border-radius: 3px;
    padding: 2px 0px 0px 4px;
    font-size: 0.9em;
    color: inherit;
}

.md-tag {
    color: #a7a7a7;
    opacity: 1;
}

.md-toc { 
    margin-top:20px;
    padding-bottom:20px;
}

.sidebar-tabs {
    border-bottom: none;
}

#typora-quick-open {
    border: 1px solid #ddd;
    background-color: #f8f8f8;
}

#typora-quick-open-item {
    background-color: #FAFAFA;
    border-color: #FEFEFE #e5e5e5 #e5e5e5 #eee;
    border-style: solid;
    border-width: 1px;
}

/** focus mode */
.on-focus-mode blockquote {
    border-left-color: rgba(85, 85, 85, 0.12);
}

header, .context-menu, .megamenu-content, footer{
    font-family: "Segoe UI", "Arial", sans-serif;
}

.file-node-content:hover .file-node-icon,
.file-node-content:hover .file-node-open-state{
    visibility: visible;
}

.mac-seamless-mode #typora-sidebar {
    background-color: #fafafa;
    background-color: var(--side-bar-bg-color);
}

.md-lang {
    color: #b4654d;
}

/*.html-for-mac {
    --item-hover-bg-color: #E6F0FE;
}*/

#md-notification .btn {
    border: 0;
}

.dropdown-menu .divider {
    border-color: #e5e5e5;
    opacity: 0.4;
}

.ty-preferences .window-content {
    background-color: #fafafa;
}

.ty-preferences .nav-group-item.active {
    color: white;
    background: #999;
}

.menu-item-container a.menu-style-btn {
    background-color: #f5f8fa;
    background-image: linear-gradient( 180deg , hsla(0, 0%, 100%, 0.8), hsla(0, 0%, 100%, 0)); 
}



</style><title>cloud_07</title>
</head>
<body class='typora-export os-windows'><div class='typora-export-content'>
<div id='write'  class=''><h1 id='kubernetes'><span>kubernetes</span></h1><div class='md-toc' mdtype='toc'><p class="md-toc-content" role="list"><span role="listitem" class="md-toc-item md-toc-h1" data-ref="n0"><a class="md-toc-inner" href="#kubernetes">kubernetes</a></span><span role="listitem" class="md-toc-item md-toc-h2" data-ref="n3"><a class="md-toc-inner" href="#资源文件模板">资源文件模板</a></span><span role="listitem" class="md-toc-item md-toc-h2" data-ref="n5"><a class="md-toc-inner" href="#控制器">控制器</a></span><span role="listitem" class="md-toc-item md-toc-h3" data-ref="n6"><a class="md-toc-inner" href="#deployment">Deployment</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n7"><a class="md-toc-inner" href="#deploy-图例">Deploy 图例</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n9"><a class="md-toc-inner" href="#资源对象案例-1">资源对象案例</a></span><span role="listitem" class="md-toc-item md-toc-h3" data-ref="n13"><a class="md-toc-inner" href="#daemonset">DaemonSet</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n14"><a class="md-toc-inner" href="#ds图例">DS图例</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n16"><a class="md-toc-inner" href="#资源对象案例-2">资源对象案例</a></span><span role="listitem" class="md-toc-item md-toc-h3" data-ref="n18"><a class="md-toc-inner" href="#jobcronjob">Job/CronJob</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n19"><a class="md-toc-inner" href="#job图例">Job图例</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n21"><a class="md-toc-inner" href="#资源对象案例-3">资源对象案例</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n23"><a class="md-toc-inner" href="#cj图例">CJ图例</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n25"><a class="md-toc-inner" href="#资源对象案例-4">资源对象案例</a></span><span role="listitem" class="md-toc-item md-toc-h3" data-ref="n27"><a class="md-toc-inner" href="#statefulset">StatefulSet</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n28"><a class="md-toc-inner" href="#sts图例">STS图例</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n30"><a class="md-toc-inner" href="#资源对象案例-5">资源对象案例</a></span><span role="listitem" class="md-toc-item md-toc-h3" data-ref="n32"><a class="md-toc-inner" href="#horizontalpodautoscaling">HorizontalPodAutoscaling</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n33"><a class="md-toc-inner" href="#hpa图例">HPA图例</a></span><span role="listitem" class="md-toc-item md-toc-h4" data-ref="n35"><a class="md-toc-inner" href="#资源对象案例-6">资源对象案例</a></span><span role="listitem" class="md-toc-item md-toc-h2" data-ref="n39"><a class="md-toc-inner" href="#项目实战">项目实战</a></span><span role="listitem" class="md-toc-item md-toc-h3" data-ref="n40"><a class="md-toc-inner" href="#项目1">项目1</a></span><span role="listitem" class="md-toc-item md-toc-h3" data-ref="n44"><a class="md-toc-inner" href="#项目2">项目2</a></span></p></div><h2 id='资源文件模板'><span>资源文件模板</span></h2><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><span><span>​</span>x</span></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># Pod 模板</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl run mypod --image=myos:httpd --dry-run=client -o yaml</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Pod</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  creationTimestamp: null</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  labels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  run: mypod</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: mypod</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;<span class="cm-attribute">-</span> image: myos:httpd</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  name: mypod</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  resources: {}</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  dnsPolicy: ClusterFirst</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  restartPolicy: Always</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">status: {}</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># Deployment 模板</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl create deployment myweb --image=myos:httpd --dry-run=client -o yaml</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: apps/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Deployment</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  creationTimestamp: null</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  labels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  app: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  replicas: <span class="cm-number">1</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  matchLabels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  app: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  strategy: {}</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  template:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  creationTimestamp: null</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  labels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  app: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> image: myos:httpd</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  name: myos</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  resources: {}</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">status: {}</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 以下资源对象都可以用模板生成</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl create &lt;tab&gt;&lt;tab&gt;</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">clusterrole &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; deployment &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; poddisruptionbudget &nbsp; &nbsp; &nbsp;  rolebinding</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">clusterrolebinding &nbsp; &nbsp;  ingress &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  priorityclass &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  secret</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">configmap &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; job &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  quota &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-builtin">service</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">cronjob &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; namespace &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  role &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; serviceaccount</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 查看帮助信息</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl explain pod.spec.restartPolicy</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">KIND: &nbsp; &nbsp; Pod</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">VERSION:  v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">FIELD: &nbsp;  restartPolicy &lt;string&gt;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">DESCRIPTION:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; Restart policy <span class="cm-keyword">for</span> all containers within the pod. </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; One of Always, OnFailure, Never. Default to Always. More info:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/<span class="cm-comment">#restart-policy</span></span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 1418px;"></div><div class="CodeMirror-gutters" style="display: none; height: 1418px;"></div></div></div></pre><h2 id='控制器'><span>控制器</span></h2><h3 id='deployment'><span>Deployment</span></h3><h4 id='deploy-图例'><span>Deploy 图例</span></h4><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart0" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="325.2001037597656" style="max-width: 251.5859375px;" viewBox="0 0 251.5859375 325.2001037597656"><style>#mermaidChart0{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart0 .error-icon{fill:#552222;}#mermaidChart0 .error-text{fill:#552222;stroke:#552222;}#mermaidChart0 .edge-thickness-normal{stroke-width:2px;}#mermaidChart0 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart0 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart0 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart0 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart0 .marker{fill:#333333;}#mermaidChart0 .marker.cross{stroke:#333333;}#mermaidChart0 svg{font-family:sans-serif;font-size:16px;}#mermaidChart0 .label{font-family:sans-serif;color:#333;}#mermaidChart0 .label text{fill:#333;}#mermaidChart0 .node rect,#mermaidChart0 .node circle,#mermaidChart0 .node ellipse,#mermaidChart0 .node polygon,#mermaidChart0 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart0 .node .label{text-align:center;}#mermaidChart0 .node.clickable{cursor:pointer;}#mermaidChart0 .arrowheadPath{fill:#333333;}#mermaidChart0 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart0 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart0 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart0 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart0 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart0 .cluster text{fill:#333;}#mermaidChart0 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart0:root{--mermaid-font-family:sans-serif;}#mermaidChart0:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart0 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;}#mermaidChart0 .Pod tspan{fill:#000000 !important;}#mermaidChart0 .Deploy &gt; *{fill:#40aff0 !important;color:#f0ff00 !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart0 .Deploy tspan{fill:#f0ff00 !important;}#mermaidChart0 flowchart-v2{fill:apa;}</style><g transform="translate(0, 0)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"></g><g class="edgePaths"><path d="M125.79296875,117.28385162353516L125.79296875,121.45051829020183C125.79296875,125.61718495686848,125.79296875,133.9505182902018,125.79296875,142.28385162353516C125.79296875,150.6171849568685,125.79296875,158.9505182902018,125.79296875,163.1171849568685L125.79296875,167.28385162353516" id="L-D-R" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-D LE-R" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M83.48394097222223,207.28385162353516L74.66956018518519,211.4505182902018C65.85517939814815,215.6171849568685,48.226417824074076,223.9505182902018,39.41203703703704,232.28385162353516C30.59765625,240.6171849568685,30.59765625,248.9505182902018,30.59765625,253.1171849568685L30.59765625,257.28385162353516" id="L-R-P1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-R LE-P1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M125.79296875,207.28385162353516L125.79296875,211.4505182902018C125.79296875,215.6171849568685,125.79296875,223.9505182902018,125.79296875,232.28385162353516C125.79296875,240.6171849568685,125.79296875,248.9505182902018,125.79296875,253.1171849568685L125.79296875,257.28385162353516" id="L-R-P2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-R LE-P2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M168.10199652777777,207.28385162353516L176.9163773148148,211.4505182902018C185.73075810185185,215.6171849568685,203.35951967592595,223.9505182902018,212.17390046296296,232.28385162353516C220.98828125,240.6171849568685,220.98828125,248.9505182902018,220.98828125,253.1171849568685L220.98828125,257.28385162353516" id="L-R-P3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-R LE-P3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default Deploy" id="flowchart-D-5" transform="translate(125.79296875, 62.64192581176758)"><circle rx="0" ry="0" r="54.64192581176758" width="109.28385162353516" height="40"></circle><g class="label" style="" transform="translate(-47.14192581176758, -12.5)"><foreignObject width="94.28385162353516" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Deployment</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-R-6" transform="translate(125.79296875, 187.28385162353516)"><rect rx="20" ry="20" x="-52.20051956176758" y="-20" width="104.40103912353516" height="40"></rect><g class="label" style="" transform="translate(-39.70051956176758, -12.5)"><foreignObject width="79.40103912353516" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>ReplicaSet</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P1-7" label-offset-y="6.638742253844389" transform="translate(30.59765625, 287.24196434020996)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P2-8" label-offset-y="6.638742253844389" transform="translate(125.79296875, 287.24196434020996)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P3-9" label-offset-y="6.638742253844389" transform="translate(220.98828125, 287.24196434020996)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g></g></g></g></svg></div><h4 id='资源对象案例-1'><span>资源对象案例</span></h4><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim mydeploy.yaml</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Deployment</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: apps/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  replicas: <span class="cm-number">2</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  matchLabels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  template:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  labels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  restartPolicy: Always</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name: apache</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  image: myos:httpd</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  ports:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  protocol: TCP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  containerPort: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f mydeploy.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get deployments.apps </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  READY &nbsp; UP-TO-DATE &nbsp; AVAILABLE &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; <span class="cm-number">2</span>/2 &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 68s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get replicasets.apps </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; DESIRED &nbsp; CURRENT &nbsp; READY &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; 73s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-5mhqn &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  76s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-nt6tz &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  76s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 创建服务访问集群</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim websvc.yaml</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Service</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: websvc</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  type: ClusterIP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  clusterIP: <span class="cm-number">10</span>.245.1.80</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  ports:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;<span class="cm-attribute">-</span> protocol: TCP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  port: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  targetPort: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f websvc.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-builtin">service</span>/websvc created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># curl -m 3 http://10.245.1.80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Welcome to The Apache.</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 自维护自治理</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-5mhqn &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  4m16s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-nt6tz &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  4m16s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># Pod 被删除后，Deploy 会自动创建新的 Pod 来维护集群的完整性</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl delete pod myweb-64b544dcbc-5mhqn </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">pod <span class="cm-string">"myweb-64b544dcbc-5mhqn"</span> deleted</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-g8l9p &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  3s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-nt6tz &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  4m25s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 动态更新集群副本数量</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl scale deployment myweb --replicas=1</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb scaled</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-nt6tz &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  5m46s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl scale deployment myweb --replicas=3</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb scaled</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-5sf5z &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  3s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-6r6dw &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  3s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc-nt6tz &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  5m56s</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 1958px;"></div><div class="CodeMirror-gutters" style="display: none; height: 1958px;"></div></div></div></pre><p><span>历史版本、滚动更新</span></p><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 添加注释信息</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl annotate deployments.apps myweb kubernetes.io/change-cause="httpd.v1"</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb annotated</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 修改镜像，滚动更新集群</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># curl -m 3 http://10.245.1.80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Welcome to The Apache.</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># sed 's,\(image: \).*,\1myos:nginx,' mydeploy.yaml |kubectl apply -f -</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb configured</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 更新注释信息</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl annotate deployments.apps myweb kubernetes.io/change-cause="nginx.v1"</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb annotated</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get replicasets.apps </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; DESIRED &nbsp; CURRENT &nbsp; READY &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-5bfdc888d7 &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; 3m46s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-64b544dcbc &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; 12m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># curl -m 3 http://10.245.1.80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Nginx is running !</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 历史版本与回滚</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl rollout history deployment myweb </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">REVISION  CHANGE-CAUSE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; httpd.v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; nginx.v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl rollout undo deployment myweb --to-revision=1</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb rolled back</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl rollout history deployment myweb </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">REVISION  CHANGE-CAUSE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp; nginx.v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; httpd.v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># curl -m 3 http://10.245.1.80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Welcome to The Apache.</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 删除控制器方法1</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl delete deployments.apps myweb </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps <span class="cm-string">"myweb"</span> deleted</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 删除控制器方法2</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl delete -f mydeploy.yaml</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps <span class="cm-string">"myweb"</span> deleted</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 945px;"></div><div class="CodeMirror-gutters" style="display: none; height: 945px;"></div></div></div></pre><h3 id='daemonset'><span>DaemonSet</span></h3><h4 id='ds图例'><span>DS图例</span></h4><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart1" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="374.6792297363281" style="max-width: 399.046875px;" viewBox="0 0 399.046875 374.6792297363281"><style>#mermaidChart1{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart1 .error-icon{fill:#552222;}#mermaidChart1 .error-text{fill:#552222;stroke:#552222;}#mermaidChart1 .edge-thickness-normal{stroke-width:2px;}#mermaidChart1 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart1 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart1 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart1 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart1 .marker{fill:#333333;}#mermaidChart1 .marker.cross{stroke:#333333;}#mermaidChart1 svg{font-family:sans-serif;font-size:16px;}#mermaidChart1 .label{font-family:sans-serif;color:#333;}#mermaidChart1 .label text{fill:#333;}#mermaidChart1 .node rect,#mermaidChart1 .node circle,#mermaidChart1 .node ellipse,#mermaidChart1 .node polygon,#mermaidChart1 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart1 .node .label{text-align:center;}#mermaidChart1 .node.clickable{cursor:pointer;}#mermaidChart1 .arrowheadPath{fill:#333333;}#mermaidChart1 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart1 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart1 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart1 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart1 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart1 .cluster text{fill:#333;}#mermaidChart1 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart1:root{--mermaid-font-family:sans-serif;}#mermaidChart1:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart1 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;}#mermaidChart1 .Pod tspan{fill:#000000 !important;}#mermaidChart1 .Deploy &gt; *{fill:#40aff0 !important;color:#f0ff00 !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart1 .Deploy tspan{fill:#f0ff00 !important;}#mermaidChart1 flowchart-v2{fill:apa;}</style><g transform="translate(0, -0.000003814697265625)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"></g><g class="edgePaths"><path d="M55.67447662353515,257.26301765441895L55.59114329020181,261.34635066986084C55.50780995686849,265.42968368530273,55.34114329020182,273.5963497161865,55.25780995686849,281.8463493982951C55.174476623535156,290.0963490804036,55.174476623535156,298.429682413737,55.174476623535156,302.5963490804036L55.174476623535156,306.7630157470703" id="L-N1-P1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-N1 LE-P1" style="fill:none;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M200.0234298706055,257.2630176544189L199.94009653727213,261.3463506698608C199.8567632039388,265.4296836853027,199.69009653727213,273.5963497161865,199.6067632039388,281.8463493982951C199.52342987060547,290.0963490804036,199.52342987060547,298.429682413737,199.52342987060547,302.5963490804036L199.52342987060547,306.7630157470703" id="L-N2-P2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-N2 LE-P2" style="fill:none;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M344.3723831176758,257.2630176544189L344.28904978434247,261.3463506698608C344.2057164510091,265.4296836853027,344.03904978434247,273.5963497161865,343.9557164510091,281.8463493982951C343.8723831176758,290.0963490804036,343.8723831176758,298.429682413737,343.8723831176758,302.5963490804036L343.8723831176758,306.7630157470703" id="L-N3-P3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-N3 LE-P3" style="fill:none;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M153.48769032233665,84.82988234775945L137.10215470586974,93.59391237313287C120.71661908940281,102.3579423985063,87.94554785646899,119.88600244925316,71.64334557333541,132.900032792518C55.34114329020182,145.91406313578287,55.50780995686849,154.41406377156576,55.59114329020182,158.66406408945718L55.67447662353515,162.91406440734863" id="L-Ds-N1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-Ds LE-N1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M199.52342987060547,112.4140625L199.52342987060547,116.58072916666667C199.52342987060547,120.74739583333333,199.52342987060547,129.08072916666666,199.6067632039388,137.49739615122476C199.69009653727213,145.91406313578284,199.8567632039388,154.4140637715657,199.94009653727218,158.66406408945713L200.0234298706055,162.91406440734855" id="L-Ds-N2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-Ds LE-N2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M245.5591694188743,84.82988234775945L261.9447050353412,93.59391237313287C278.3302406518081,102.3579423985063,311.10131188474196,119.88600244925316,327.5701808345422,132.90003279251798C344.03904978434247,145.91406313578284,344.2057164510091,154.4140637715657,344.28904978434247,158.66406408945713L344.3723831176758,162.91406440734855" id="L-Ds-N3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-Ds LE-N3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default Pod" id="flowchart-N1-20" transform="translate(55.174476623535156, 209.58853912353516)"><polygon points="47.17447853088379,0 94.34895706176758,-47.17447853088379 47.17447853088379,-94.34895706176758 0,-47.17447853088379" class="label-container" transform="translate(-47.17447853088379,47.17447853088379)"></polygon><g class="label" style="" transform="translate(-19.67447853088379, -12.5)"><foreignObject width="39.34895706176758" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>node</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P1-21" label-offset-y="6.638742253844389" transform="translate(55.174476623535156, 336.7211284637451)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-N2-22" transform="translate(199.52342987060547, 209.58853912353516)"><polygon points="47.17447853088379,0 94.34895706176758,-47.17447853088379 47.17447853088379,-94.34895706176758 0,-47.17447853088379" class="label-container" transform="translate(-47.17447853088379,47.17447853088379)"></polygon><g class="label" style="" transform="translate(-19.67447853088379, -12.5)"><foreignObject width="39.34895706176758" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>node</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P2-23" label-offset-y="6.638742253844389" transform="translate(199.52342987060547, 336.7211284637451)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-N3-24" transform="translate(343.8723831176758, 209.58853912353516)"><polygon points="47.17447853088379,0 94.34895706176758,-47.17447853088379 47.17447853088379,-94.34895706176758 0,-47.17447853088379" class="label-container" transform="translate(-47.17447853088379,47.17447853088379)"></polygon><g class="label" style="" transform="translate(-19.67447853088379, -12.5)"><foreignObject width="39.34895706176758" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>node</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P3-25" label-offset-y="6.638742253844389" transform="translate(343.8723831176758, 336.7211284637451)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Deploy" id="flowchart-Ds-26" transform="translate(199.52342987060547, 60.20703125)"><circle rx="0" ry="0" r="52.20703125" width="104.4140625" height="40"></circle><g class="label" style="" transform="translate(-44.70703125, -12.5)"><foreignObject width="89.4140625" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>DaemonSet</span></div></foreignObject></g></g></g></g></g></svg></div><h4 id='资源对象案例-2'><span>资源对象案例</span></h4><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim myds.yaml</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: DaemonSet</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: apps/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: myds</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  matchLabels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  template:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  labels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  restartPolicy: Always</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name: apache</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  image: myos:httpd</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  ports:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  protocol: TCP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  containerPort: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f myds.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">daemonset.apps/myds created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods -o wide</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE &nbsp; IP &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  NODE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myds-4wt72 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  31s &nbsp; <span class="cm-number">10</span>.244.3.14 &nbsp; node-0003</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myds-lwq8l &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  31s &nbsp; <span class="cm-number">10</span>.244.2.17 &nbsp; node-0002</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myds-msrcx &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  31s &nbsp; <span class="cm-number">10</span>.244.1.11 &nbsp; node-0001</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 删除DS控制器</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl delete -f myds.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">daemonset.apps <span class="cm-string">"myds"</span> deleted</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 788px;"></div><div class="CodeMirror-gutters" style="display: none; height: 788px;"></div></div></div></pre><h3 id='jobcronjob'><span>Job/CronJob</span></h3><h4 id='job图例'><span>Job图例</span></h4><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart2" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="75.91622924804688" style="max-width: 172.9270782470703px;" viewBox="0 0 172.9270782470703 75.91622924804688"><style>#mermaidChart2{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart2 .error-icon{fill:#552222;}#mermaidChart2 .error-text{fill:#552222;stroke:#552222;}#mermaidChart2 .edge-thickness-normal{stroke-width:2px;}#mermaidChart2 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart2 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart2 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart2 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart2 .marker{fill:#333333;}#mermaidChart2 .marker.cross{stroke:#333333;}#mermaidChart2 svg{font-family:sans-serif;font-size:16px;}#mermaidChart2 .label{font-family:sans-serif;color:#333;}#mermaidChart2 .label text{fill:#333;}#mermaidChart2 .node rect,#mermaidChart2 .node circle,#mermaidChart2 .node ellipse,#mermaidChart2 .node polygon,#mermaidChart2 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart2 .node .label{text-align:center;}#mermaidChart2 .node.clickable{cursor:pointer;}#mermaidChart2 .arrowheadPath{fill:#333333;}#mermaidChart2 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart2 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart2 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart2 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart2 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart2 .cluster text{fill:#333;}#mermaidChart2 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart2:root{--mermaid-font-family:sans-serif;}#mermaidChart2:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart2 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;}#mermaidChart2 .Pod tspan{fill:#000000 !important;}#mermaidChart2 .Deploy &gt; *{fill:#40aff0 !important;color:#f0ff00 !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart2 .Deploy tspan{fill:#f0ff00 !important;}#mermaidChart2 flowchart-v2{fill:apa;}</style><g transform="translate(0, 0)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"></g><g class="edgePaths"><path d="M38.86588478088379,37.958112716674805L48.176865577697754,37.958112716674805C57.48784637451172,37.958112716674805,76.10980796813965,37.958112716674805,89.58745543162028,37.958112716674805C103.0651028951009,37.958112716674805,111.39843622843425,37.958112716674805,115.5651028951009,37.958112716674805L119.73176956176758,37.958112716674805" id="L-Job-P" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-Job LE-P" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default Deploy" id="flowchart-Job-32" transform="translate(38.86588478088379, 37.958112716674805)"><polygon points="10,0 51.73176956176758,0 61.73176956176758,-20 51.73176956176758,-40 10,-40 0,-20" class="label-container" transform="translate(-30.86588478088379,20)"></polygon><g class="label" style="" transform="translate(-13.365884780883789, -12.5)"><foreignObject width="26.731769561767578" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Job</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P-33" label-offset-y="6.638742253844389" transform="translate(142.32942581176758, 37.958112716674805)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g></g></g></g></svg></div><h4 id='资源对象案例-3'><span>资源对象案例</span></h4><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim myjob.yaml </span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Job</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: batch/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: myjob</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  template:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  restartPolicy: OnFailure</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name: myjob</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  image: myos:latest</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  command: [<span class="cm-string">"/bin/sleep"</span>, <span class="cm-string">"30"</span>]</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f myjob.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">job.batch/myjob created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get jobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  COMPLETIONS &nbsp; DURATION &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myjob &nbsp; <span class="cm-number">0</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 3s &nbsp; &nbsp; &nbsp; &nbsp; 3s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods -l job-name=myjob</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myjob--1-kz8mk &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  6s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># sleep 30</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods -l job-name=myjob</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp; &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myjob--1-kz8mk &nbsp; <span class="cm-number">0</span>/1 &nbsp; &nbsp; Completed &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  58s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get jobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  COMPLETIONS &nbsp; DURATION &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myjob &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31s &nbsp; &nbsp; &nbsp;  64s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 删除Job控制器</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl delete -f myjob.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">job.batch <span class="cm-string">"myjob"</span> deleted</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 765px;"></div><div class="CodeMirror-gutters" style="display: none; height: 765px;"></div></div></div></pre><h4 id='cj图例'><span>CJ图例</span></h4><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart3" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="294.4969482421875" style="max-width: 301.1953125px;" viewBox="0 0 301.1953125 294.4969482421875"><style>#mermaidChart3{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart3 .error-icon{fill:#552222;}#mermaidChart3 .error-text{fill:#552222;stroke:#552222;}#mermaidChart3 .edge-thickness-normal{stroke-width:2px;}#mermaidChart3 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart3 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart3 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart3 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart3 .marker{fill:#333333;}#mermaidChart3 .marker.cross{stroke:#333333;}#mermaidChart3 svg{font-family:sans-serif;font-size:16px;}#mermaidChart3 .label{font-family:sans-serif;color:#333;}#mermaidChart3 .label text{fill:#333;}#mermaidChart3 .node rect,#mermaidChart3 .node circle,#mermaidChart3 .node ellipse,#mermaidChart3 .node polygon,#mermaidChart3 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart3 .node .label{text-align:center;}#mermaidChart3 .node.clickable{cursor:pointer;}#mermaidChart3 .arrowheadPath{fill:#333333;}#mermaidChart3 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart3 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart3 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart3 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart3 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart3 .cluster text{fill:#333;}#mermaidChart3 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart3:root{--mermaid-font-family:sans-serif;}#mermaidChart3:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart3 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;}#mermaidChart3 .Pod tspan{fill:#000000 !important;}#mermaidChart3 .Deploy &gt; *{fill:#40aff0 !important;color:#f0ff00 !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart3 .Deploy tspan{fill:#f0ff00 !important;}#mermaidChart3 flowchart-v2{fill:apa;}</style><g transform="translate(0, -0.000003814697265625)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"></g><g class="edgePaths"><path d="M38.86588478088379,156.58072662353516L38.86588478088379,164.08072662353516C38.86588478088379,171.58072662353516,38.86588478088379,186.58072662353516,38.86588478088379,198.2473932902018C38.86588478088379,209.9140599568685,38.86588478088379,218.2473932902018,38.86588478088379,222.4140599568685L38.86588478088379,226.58072662353516" id="L-Job1-P1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-Job1 LE-P1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M150.59765434265137,156.58072662353516L150.59765434265137,164.08072662353516C150.59765434265137,171.58072662353516,150.59765434265137,186.58072662353516,150.59765434265137,198.2473932902018C150.59765434265137,209.9140599568685,150.59765434265137,218.2473932902018,150.59765434265137,222.4140599568685L150.59765434265137,226.58072662353516" id="L-Job2-P2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-Job2 LE-P2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M262.32942390441895,156.58072662353516L262.32942390441895,164.08072662353516C262.32942390441895,171.58072662353516,262.32942390441895,186.58072662353516,262.32942390441895,198.2473932902018C262.32942390441895,209.9140599568685,262.32942390441895,218.2473932902018,262.32942390441895,222.4140599568685L262.32942390441895,226.58072662353516" id="L-Job3-P3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-Job3 LE-P3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M116.5424659850375,66.88568915999303L103.59636911767855,74.33486207058338C90.65027225031959,81.78403498117375,64.7580785156017,96.68238080235444,51.81198164824274,111.63155371294481C38.86588478088379,126.58072662353516,38.86588478088379,141.58072662353516,38.86588478088379,149.08072662353516L38.86588478088379,156.58072662353516" id="L-CJob-Job1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-CJob LE-Job1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M150.59765434265137,86.58072662353516L150.59765434265137,90.74739329020183C150.59765434265137,94.91405995686848,150.59765434265137,103.24739329020183,150.59765434265137,114.91405995686848C150.59765434265137,126.58072662353516,150.59765434265137,141.58072662353516,150.59765434265137,149.08072662353516L150.59765434265137,156.58072662353516" id="L-CJob-Job2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-CJob LE-Job2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M184.65284270026524,66.88568915999303L197.59893956762417,74.33486207058338C210.54503643498313,81.78403498117375,236.43723016970102,96.68238080235444,249.38332703705998,111.63155371294481C262.32942390441895,126.58072662353516,262.32942390441895,141.58072662353516,262.32942390441895,149.08072662353516L262.32942390441895,156.58072662353516" id="L-CJob-Job3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-CJob LE-Job3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default Pod" id="flowchart-Job1-44" transform="translate(38.86588478088379, 156.58072662353516)"><polygon points="10,0 51.73176956176758,0 61.73176956176758,-20 51.73176956176758,-40 10,-40 0,-20" class="label-container" transform="translate(-30.86588478088379,20)"></polygon><g class="label" style="" transform="translate(-13.365884780883789, -12.5)"><foreignObject width="26.731769561767578" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Job</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P1-45" label-offset-y="6.638742253844389" transform="translate(38.86588478088379, 256.53883934020996)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-Job2-46" transform="translate(150.59765434265137, 156.58072662353516)"><polygon points="10,0 51.73176956176758,0 61.73176956176758,-20 51.73176956176758,-40 10,-40 0,-20" class="label-container" transform="translate(-30.86588478088379,20)"></polygon><g class="label" style="" transform="translate(-13.365884780883789, -12.5)"><foreignObject width="26.731769561767578" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Job</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P2-47" label-offset-y="6.638742253844389" transform="translate(150.59765434265137, 256.53883934020996)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-Job3-48" transform="translate(262.32942390441895, 156.58072662353516)"><polygon points="10,0 51.73176956176758,0 61.73176956176758,-20 51.73176956176758,-40 10,-40 0,-20" class="label-container" transform="translate(-30.86588478088379,20)"></polygon><g class="label" style="" transform="translate(-13.365884780883789, -12.5)"><foreignObject width="26.731769561767578" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Job</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P3-49" label-offset-y="6.638742253844389" transform="translate(262.32942390441895, 256.53883934020996)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Deploy" id="flowchart-CJob-50" transform="translate(150.59765434265137, 47.29036331176758)"><circle rx="0" ry="0" r="39.29036331176758" width="78.58072662353516" height="40"></circle><g class="label" style="" transform="translate(-31.790363311767578, -12.5)"><foreignObject width="63.580726623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>CronJob</span></div></foreignObject></g></g></g></g></g></svg></div><h4 id='资源对象案例-4'><span>资源对象案例</span></h4><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim mycj.yaml</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: CronJob</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: batch/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: mycronjob</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  schedule: <span class="cm-string">"*/1 * * * 1-5"</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  jobTemplate:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  template:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  restartPolicy: OnFailure</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name: myjob</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  image: myos:latest</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  command: [<span class="cm-string">"/bin/sleep"</span>, <span class="cm-string">"30"</span>]</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f mycj.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">cronjob.batch/mycronjob created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get cronjobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp;  SCHEDULE &nbsp; &nbsp; &nbsp;  SUSPEND &nbsp; ACTIVE &nbsp; LAST SCHEDULE &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob &nbsp; */1 * * * <span class="cm-number">1</span><span class="cm-attribute">-5</span> &nbsp; False &nbsp; &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp;  &lt;none&gt; &nbsp; &nbsp; &nbsp; &nbsp;  4s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get jobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">No resources found <span class="cm-keyword">in</span> default namespace.</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">No resources found <span class="cm-keyword">in</span> default namespace.</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># sleep 60</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get jobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; COMPLETIONS &nbsp; DURATION &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605367 &nbsp; <span class="cm-number">0</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 0s &nbsp; &nbsp; &nbsp; &nbsp; 0s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605367--1-ps6r8 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  3s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get jobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; COMPLETIONS &nbsp; DURATION &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605367 &nbsp; <span class="cm-number">0</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 12s &nbsp; &nbsp; &nbsp;  12s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># sleep 200</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 保留三次结果，多余的会被删除</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get jobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; COMPLETIONS &nbsp; DURATION &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605367 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31s &nbsp; &nbsp; &nbsp;  3m30s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605368 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31s &nbsp; &nbsp; &nbsp;  2m30s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605369 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31s &nbsp; &nbsp; &nbsp;  90s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605370 &nbsp; <span class="cm-number">0</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 30s &nbsp; &nbsp; &nbsp;  30s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get jobs.batch </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; COMPLETIONS &nbsp; DURATION &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605368 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31s &nbsp; &nbsp; &nbsp;  2m33s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605369 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31s &nbsp; &nbsp; &nbsp;  93s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mycronjob-27605370 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31s &nbsp; &nbsp; &nbsp;  33s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 删除CJ控制器</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl delete -f mycj.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">cronjob.batch <span class="cm-string">"mycronjob"</span> deleted</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 1238px;"></div><div class="CodeMirror-gutters" style="display: none; height: 1238px;"></div></div></div></pre><h3 id='statefulset'><span>StatefulSet</span></h3><h4 id='sts图例'><span>STS图例</span></h4><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart4" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="295.7486572265625" style="max-width: 458.5650939941406px;" viewBox="0 0 458.5650939941406 295.7486572265625"><style>#mermaidChart4{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart4 .error-icon{fill:#552222;}#mermaidChart4 .error-text{fill:#552222;stroke:#552222;}#mermaidChart4 .edge-thickness-normal{stroke-width:2px;}#mermaidChart4 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart4 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart4 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart4 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart4 .marker{fill:#333333;}#mermaidChart4 .marker.cross{stroke:#333333;}#mermaidChart4 svg{font-family:sans-serif;font-size:16px;}#mermaidChart4 .label{font-family:sans-serif;color:#333;}#mermaidChart4 .label text{fill:#333;}#mermaidChart4 .node rect,#mermaidChart4 .node circle,#mermaidChart4 .node ellipse,#mermaidChart4 .node polygon,#mermaidChart4 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart4 .node .label{text-align:center;}#mermaidChart4 .node.clickable{cursor:pointer;}#mermaidChart4 .arrowheadPath{fill:#333333;}#mermaidChart4 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart4 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart4 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart4 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart4 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart4 .cluster text{fill:#333;}#mermaidChart4 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart4:root{--mermaid-font-family:sans-serif;}#mermaidChart4:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart4 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;}#mermaidChart4 .Pod tspan{fill:#000000 !important;}#mermaidChart4 .Deploy &gt; *{fill:#40aff0 !important;color:#f0ff00 !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart4 .Deploy tspan{fill:#f0ff00 !important;}#mermaidChart4 flowchart-v2{fill:apa;}</style><g transform="translate(0, 0)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"></g><g class="edgePaths"><path d="M91.86639263163946,104.58512040350918L99.75715010969954,93.48061912237011C107.64790758775963,82.37611784123105,123.42942254387981,60.16711527895293,135.48684668860656,49.06261399781386C147.54427083333334,37.958112716674805,155.87760416666666,37.958112716674805,164.2109375,37.958112716674805C172.54427083333334,37.958112716674805,180.87760416666666,37.958112716674805,189.2109375,37.958112716674805C197.54427083333334,37.958112716674805,205.87760416666666,37.958112716674805,210.04427083333334,37.958112716674805L214.2109375,37.958112716674805" id="L-S-P1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-S LE-P1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M114.2109375,147.8743381500244L118.37760416666667,147.8743381500244C122.54427083333333,147.8743381500244,130.87760416666666,147.8743381500244,139.2109375,147.8743381500244C147.54427083333334,147.8743381500244,155.87760416666666,147.8743381500244,164.2109375,147.8743381500244C172.54427083333334,147.8743381500244,180.87760416666666,147.8743381500244,189.2109375,147.8743381500244C197.54427083333334,147.8743381500244,205.87760416666666,147.8743381500244,210.04427083333334,147.8743381500244L214.2109375,147.8743381500244" id="L-S-P2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-S LE-P2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M91.86639263163946,191.16355589653966L99.75715010969954,202.26805717767874C107.64790758775963,213.3725584588178,123.42942254387981,235.58156102109592,135.48684668860656,246.68606230223497C147.54427083333334,257.790563583374,155.87760416666666,257.790563583374,164.2109375,257.790563583374C172.54427083333334,257.790563583374,180.87760416666666,257.790563583374,189.2109375,257.790563583374C197.54427083333334,257.790563583374,205.87760416666666,257.790563583374,210.04427083333334,257.790563583374L214.2109375,257.790563583374" id="L-S-P3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-S LE-P3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M259.40625,37.958112716674805L263.5729166666667,37.958112716674805C267.7395833333333,37.958112716674805,276.0729166666667,37.958112716674805,284.40625,37.958112716674805C292.7395833333333,37.958112716674805,301.0729166666667,37.958112716674805,309.40625,37.958112716674805C317.7395833333333,37.958112716674805,326.0729166666667,37.958112716674805,339.86242038829187,52.94415028889974C353.65192410991705,67.93018786112468,372.89759821983415,97.90226300557454,382.5204352747926,112.88830057779948L392.14327232975114,127.87433815002441" id="L-P1-SVC" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-P1 LE-SVC" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M259.40625,147.8743381500244L263.5729166666667,147.8743381500244C267.7395833333333,147.8743381500244,276.0729166666667,147.8743381500244,284.40625,147.8743381500244C292.7395833333333,147.8743381500244,301.0729166666667,147.8743381500244,309.40625,147.8743381500244C317.7395833333333,147.8743381500244,326.0729166666667,147.8743381500244,334.40625,147.8743381500244C342.7395833333333,147.8743381500244,351.0729166666667,147.8743381500244,355.2395833333333,147.8743381500244L359.40625,147.8743381500244" id="L-P2-SVC" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-P2 LE-SVC" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M259.40625,257.790563583374L263.5729166666667,257.790563583374C267.7395833333333,257.790563583374,276.0729166666667,257.790563583374,284.40625,257.790563583374C292.7395833333333,257.790563583374,301.0729166666667,257.790563583374,309.40625,257.790563583374C317.7395833333333,257.790563583374,326.0729166666667,257.790563583374,339.86242038829187,242.80452601114908C353.65192410991705,227.81848843892416,372.89759821983415,197.84641329447427,382.5204352747926,182.86037572224936L392.14327232975114,167.8743381500244" id="L-P3-SVC" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-P3 LE-SVC" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default Deploy" id="flowchart-S-59" transform="translate(61.10546875, 147.8743381500244)"><circle rx="0" ry="0" r="53.10546875" width="106.2109375" height="40"></circle><g class="label" style="" transform="translate(-45.60546875, -12.5)"><foreignObject width="91.2109375" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>StatusfulSet</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P1-60" label-offset-y="6.638742253844389" transform="translate(236.80859375, 37.958112716674805)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P2-61" label-offset-y="6.638742253844389" transform="translate(236.80859375, 147.8743381500244)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P3-62" label-offset-y="6.638742253844389" transform="translate(236.80859375, 257.790563583374)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-SVC-63" transform="translate(404.9856758117676, 147.8743381500244)"><rect rx="20" ry="20" x="-45.57942581176758" y="-20" width="91.15885162353516" height="40"></rect><g class="label" style="" transform="translate(-33.07942581176758, -12.5)"><foreignObject width="66.15885162353516" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>headless</span></div></foreignObject></g></g></g></g></g></svg></div><h4 id='资源对象案例-5'><span>资源对象案例</span></h4><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 配置headless服务</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim mysvc.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Service</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: mysvc</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  type: ClusterIP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  clusterIP: None</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  ports:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;<span class="cm-attribute">-</span> protocol: TCP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  port: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  targetPort: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f mysvc.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-builtin">service</span>/mysvc created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get service</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; TYPE &nbsp; &nbsp; &nbsp;  CLUSTER-IP &nbsp;  EXTERNAL-IP &nbsp; PORT(S) &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysvc &nbsp; &nbsp; &nbsp;  ClusterIP &nbsp; None &nbsp; &nbsp; &nbsp; &nbsp;  &lt;none&gt; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-number">80</span>/TCP &nbsp;  61s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 创建statefulset控制器</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim mysts.yaml</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: StatefulSet</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: apps/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: mysts</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  serviceName: <span class="cm-string">"mysvc"</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  matchExpressions:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-attribute">-</span> key: app</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  operator: In</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  values:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  replicas: <span class="cm-number">3</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  template:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  labels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  restartPolicy: Always</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name: apache</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  image: myos:httpd</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  imagePullPolicy: Always</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  ports:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> protocol: TCP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  containerPort: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f mysts.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">statefulset.apps/mysts created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp;  READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysts-0 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  4s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysts-1 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  3s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysts-2 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  2s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># host mysts-0.mysvc.default.svc.cluster.local 10.245.0.10</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Using domain server:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Name: <span class="cm-number">10</span>.245.0.10</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Address: <span class="cm-number">10</span>.245.0.10<span class="cm-comment">#53</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Aliases: </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysts-0.mysvc.default.svc.cluster.local has address <span class="cm-number">10</span>.244.3.81</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># host mysvc.default.svc.cluster.local 10.245.0.10</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Using domain server:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Name: <span class="cm-number">10</span>.245.0.10</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Address: <span class="cm-number">10</span>.245.0.10<span class="cm-comment">#53</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Aliases: </span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysvc.default.svc.cluster.local has address <span class="cm-number">10</span>.244.2.10</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysvc.default.svc.cluster.local has address <span class="cm-number">10</span>.244.1.12</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">mysvc.default.svc.cluster.local has address <span class="cm-number">10</span>.244.3.11</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># curl -m 3 http://10.244.2.10/info.php</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">&lt;pre&gt;</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Array</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">(</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  [REMOTE_ADDR] <span class="cm-operator">=</span>&gt; <span class="cm-number">10</span>.244.0.0</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  [REQUEST_METHOD] <span class="cm-operator">=</span>&gt; GET</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  [HTTP_USER_AGENT] <span class="cm-operator">=</span>&gt; <span class="cm-builtin">curl</span>/7.29.0</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  [REQUEST_URI] <span class="cm-operator">=</span>&gt; /info.php</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">)</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">php_host: &nbsp; &nbsp; &nbsp; mysts-2</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-number">1229</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 删除sts控制器</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl delete -f mysts.yaml -f mysvc.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">statefulset.apps <span class="cm-string">"mysts"</span> deleted</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-builtin">service</span> <span class="cm-string">"mysvc"</span> deleted</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 2115px;"></div><div class="CodeMirror-gutters" style="display: none; height: 2115px;"></div></div></div></pre><h3 id='horizontalpodautoscaling'><span>HorizontalPodAutoscaling</span></h3><h4 id='hpa图例'><span>HPA图例</span></h4><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart5" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="367.7486877441406" style="max-width: 690.9218139648438px;" viewBox="0 0 690.9218139648438 367.7486877441406"><style>#mermaidChart5{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart5 .error-icon{fill:#552222;}#mermaidChart5 .error-text{fill:#552222;stroke:#552222;}#mermaidChart5 .edge-thickness-normal{stroke-width:2px;}#mermaidChart5 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart5 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart5 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart5 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart5 .marker{fill:#333333;}#mermaidChart5 .marker.cross{stroke:#333333;}#mermaidChart5 svg{font-family:sans-serif;font-size:16px;}#mermaidChart5 .label{font-family:sans-serif;color:#333;}#mermaidChart5 .label text{fill:#333;}#mermaidChart5 .node rect,#mermaidChart5 .node circle,#mermaidChart5 .node ellipse,#mermaidChart5 .node polygon,#mermaidChart5 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart5 .node .label{text-align:center;}#mermaidChart5 .node.clickable{cursor:pointer;}#mermaidChart5 .arrowheadPath{fill:#333333;}#mermaidChart5 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart5 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart5 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart5 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart5 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart5 .cluster text{fill:#333;}#mermaidChart5 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart5:root{--mermaid-font-family:sans-serif;}#mermaidChart5:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart5 .PodCluster &gt; *{fill:#ffffc0 !important;color:#ff00ff !important;stroke-width:4px !important;}#mermaidChart5 .PodCluster tspan{fill:#ff00ff !important;}#mermaidChart5 .Pod1 &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;}#mermaidChart5 .Pod1 tspan{fill:#000000 !important;}#mermaidChart5 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;stroke:#f06080 !important;stroke-dasharray:6 !important;3 !important;}#mermaidChart5 .Pod tspan{fill:#000000 !important;}#mermaidChart5 .Deploy &gt; *{fill:#40aff0 !important;color:#f0ff00 !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart5 .Deploy tspan{fill:#f0ff00 !important;}#mermaidChart5 flowchart-v2{fill:apa;}</style><g transform="translate(0, 2)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"><g class="cluster PodCluster PodCluster" id="C1"><rect rx="0" ry="0" x="433.3255081176758" y="8" width="249.59635162353516" height="349.7486763000488"></rect><g class="cluster-label" transform="translate(515.3111839294434, 6)"><foreignObject width="85.625" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod cluster</span></div></foreignObject></g></g></g><g class="edgePaths"><path d="M534.2953511197625,162.8743381500244L543.2005504733372,155.38131936391196C552.105749826912,147.88830057779947,569.9161485340614,132.90226300557455,582.9880145543028,121.47364141017856C596.0598805745443,110.04501981478256,604.3932139078776,102.1738141962155,608.5598805745443,98.23821138693198L612.7265472412109,94.30260857764844" id="L-R-P1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-R LE-P1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M562.7265472412109,182.8743381500244L566.8932139078776,182.8743381500244C571.0598805745443,182.8743381500244,579.3932139078776,182.8743381500244,587.7265472412109,182.8743381500244C596.0598805745443,182.8743381500244,604.3932139078776,182.8743381500244,608.5598805745443,182.8743381500244L612.7265472412109,182.8743381500244" id="L-R-P2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-R LE-P2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M524.5731839127294,202.8743381500244L535.0987444674763,217.86037572224936C545.6243050222232,232.84641329447427,566.675426131717,262.81848843892413,581.3676533531307,277.8045260111491C596.0598805745443,292.790563583374,604.3932139078776,292.790563583374,608.5598805745443,292.790563583374L612.7265472412109,292.790563583374" id="L-R-P3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-R LE-P3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M164.42890547957344,147.9162254333496L178.53103064866798,153.7425775527954C192.6331558177625,159.5689296722412,220.83740615595158,171.2216339111328,239.10619799171275,177.0479860305786C257.37498982747394,182.8743381500244,265.7083231608073,182.8743381500244,269.87498982747394,182.8743381500244L274.0416564941406,182.8743381500244" id="L-HPA-D" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-HPA LE-D" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M383.3255081176758,182.8743381500244L387.49217478434247,182.8743381500244C391.6588414510091,182.8743381500244,399.99217478434247,182.8743381500244,408.3255081176758,182.8743381500244C416.6588414510091,182.8743381500244,424.99217478434247,182.8743381500244,433.3255081176758,182.8743381500244C441.6588414510091,182.8743381500244,449.99217478434247,182.8743381500244,454.1588414510091,182.8743381500244L458.3255081176758,182.8743381500244" id="L-D-R" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-D LE-R" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M155.4711284514302,107.91622543334961L171.0662164585486,100.01003058751424C186.66130446566703,92.10383574167888,217.8514804799038,76.29144605000813,246.72022278898348,68.38525120417277C275.58896509806317,60.4790563583374,302.13627370198566,60.4790563583374,328.6835823059082,60.4790563583374C355.23089090983075,60.4790563583374,381.77819951375324,60.4790563583374,399.21852048238117,60.4790563583374C416.6588414510091,60.4790563583374,424.99217478434247,60.4790563583374,429.158842086792,60.4790563583374C433.3255093892415,60.4790563583374,433.3255106608073,60.4790563583374,433.32551129659015,60.4790563583374L433.32551193237305,60.4790563583374" id="L-HPA-C1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-HPA LE-C1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default Pod1" id="flowchart-P1-74" label-offset-y="6.638742253844389" transform="translate(635.3242034912109, 72.9581127166748)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P2-75" label-offset-y="6.638742253844389" transform="translate(635.3242034912109, 182.8743381500244)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-P3-76" label-offset-y="6.638742253844389" transform="translate(635.3242034912109, 292.790563583374)"><path d="M 0,6.638742253844389 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 a 22.59765625,6.638742253844389 0,0,0 -45.1953125 0 l 0,46.638742253844384 a 22.59765625,6.638742253844389 0,0,0 45.1953125 0 l 0,-46.638742253844384" transform="translate(-22.59765625,-29.95811338076658)"></path><g class="label" style="" transform="translate(-15.09765625, -12.5)"><foreignObject width="30.1953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Pod</span></div></foreignObject></g></g><g class="node default Pod1" id="flowchart-R-73" transform="translate(510.52602767944336, 182.8743381500244)"><rect rx="20" ry="20" x="-52.20051956176758" y="-20" width="104.40103912353516" height="40"></rect><g class="label" style="" transform="translate(-39.70051956176758, -12.5)"><foreignObject width="79.40103912353516" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>ReplicaSet</span></div></foreignObject></g></g><g class="node default Deploy" id="flowchart-HPA-77" transform="translate(116.02082824707031, 127.91622543334961)"><rect rx="20" ry="20" x="-108.02082824707031" y="-20" width="216.04165649414062" height="40"></rect><g class="label" style="" transform="translate(-95.52082824707031, -12.5)"><foreignObject width="191.04165649414062" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>HorizontalPodAutoscaler</span></div></foreignObject></g></g><g class="node default Deploy" id="flowchart-D-80" transform="translate(328.6835823059082, 182.8743381500244)"><circle rx="0" ry="0" r="54.64192581176758" width="109.28385162353516" height="40"></circle><g class="label" style="" transform="translate(-47.14192581176758, -12.5)"><foreignObject width="94.28385162353516" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Deployment</span></div></foreignObject></g></g></g></g></g></svg></div><h4 id='资源对象案例-6'><span>资源对象案例</span></h4><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 为 Deploy 模板添加资源配额</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim mydeploy.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Deployment</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: apps/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  replicas: <span class="cm-number">1</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  matchLabels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  template:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  labels:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  restartPolicy: Always</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;  containers:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name: apache</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  image: myos:httpd</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  ports:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-attribute">-</span> name:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  protocol: TCP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  containerPort: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp;  resources:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp;  requests:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  cpu: <span class="cm-string">"200m"</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: Service</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: websvc</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  type: ClusterIP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  clusterIP: <span class="cm-number">10</span>.245.1.80</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  selector:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  app: myhttp</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  ports:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;<span class="cm-attribute">-</span> protocol: TCP</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  port: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  targetPort: <span class="cm-number">80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 使用 Deploy 和 Cluster IP 创建集群</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f mydeploy.yaml</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">deployment.apps/myweb created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-builtin">service</span>/websvc created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; STATUS &nbsp;  RESTARTS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-5946bb4c68-c8tm2 &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  2m43s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># curl -s http://10.245.1.80</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">Welcome to The Apache.</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 创建 HPA 控制器</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># vim myhpa.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-attribute">---</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">kind: HorizontalPodAutoscaler</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">apiVersion: autoscaling/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">metadata:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  name: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">spec:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  minReplicas: <span class="cm-number">1</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  maxReplicas: <span class="cm-number">3</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  scaleTargetRef:</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  kind: Deployment</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  apiVersion: apps/v1</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp;  name: myweb</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">  targetCPUUtilizationPercentage: <span class="cm-number">50</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl apply -f myhpa.yaml </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">horizontalpodautoscaler.autoscaling/myweb created</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 刚刚创建 unknown 是正常现象，最多等待 300s 就可以正常获取数据</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get horizontalpodautoscalers.autoscaling </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  REFERENCE &nbsp; &nbsp; &nbsp; &nbsp;  TARGETS &nbsp; &nbsp; &nbsp; &nbsp; MINPODS &nbsp; MAXPODS &nbsp; REPLICAS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; &lt;unknown&gt;/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp;  4s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get horizontalpodautoscalers.autoscaling </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  REFERENCE &nbsp; &nbsp; &nbsp; &nbsp;  TARGETS &nbsp; &nbsp; &nbsp; &nbsp; MINPODS &nbsp; MAXPODS &nbsp; REPLICAS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">0</span>%/50% &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp;  71s</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 1823px;"></div><div class="CodeMirror-gutters" style="display: none; height: 1823px;"></div></div></div></pre><p><span>扩容测试</span></p><pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="shell" style="break-inside: unset;"><div class="CodeMirror cm-s-inner cm-s-null-scroll CodeMirror-wrap" lang="shell"><div style="overflow: hidden; position: relative; width: 3px; height: 0px; top: 9.25px; left: 7.99481px;"><textarea autocorrect="off" autocapitalize="off" spellcheck="false" tabindex="0" style="position: absolute; bottom: -1em; padding: 0px; width: 1000px; height: 1em; outline: none;"></textarea></div><div class="CodeMirror-scrollbar-filler" cm-not-content="true"></div><div class="CodeMirror-gutter-filler" cm-not-content="true"></div><div class="CodeMirror-scroll" tabindex="-1"><div class="CodeMirror-sizer" style="margin-left: 0px; margin-bottom: 0px; border-right-width: 0px; padding-right: 0px; padding-bottom: 0px;"><div style="position: relative; top: 0px;"><div class="CodeMirror-lines" role="presentation"><div role="presentation" style="position: relative; outline: none;"><div class="CodeMirror-measure"><pre><span>xxxxxxxxxx</span></pre></div><div class="CodeMirror-measure"></div><div style="position: relative; z-index: 1;"></div><div class="CodeMirror-code" role="presentation" style=""><div class="CodeMirror-activeline" style="position: relative;"><div class="CodeMirror-activeline-background CodeMirror-linebackground"></div><div class="CodeMirror-gutter-background CodeMirror-activeline-gutter" style="left: 0px; width: 0px;"></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 终端 1 访问提高负载</span></span></pre></div><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># while true;do</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-builtin">curl</span> <span class="cm-attribute">-s</span> <span class="cm-string">"http://10.245.1.80/info.php?id=50000"</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"> &nbsp; &nbsp;<span class="cm-builtin">sleep</span> <span class="cm-number">1</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-keyword">done</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 终端 2 监控 HPA 变化</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get hpa -w</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  REFERENCE &nbsp; &nbsp; &nbsp; &nbsp;  TARGETS &nbsp; MINPODS &nbsp; MAXPODS &nbsp; REPLICAS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">0</span>%/50% &nbsp; &nbsp;<span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp;  8m21s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">49</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp;  9m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">56</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp;  9m15s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">56</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  9m30s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">37</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  9m45s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">32</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  10m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">41</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  11m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">48</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  11m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">51</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  11m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">59</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  11m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">58</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  12m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">42</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  12m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">34</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  12m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span cm-text="" cm-zwsp="">
</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;"><span class="cm-comment"># 如果 300s 内平均负载小于标准值，就会自动缩减集群规模</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get hpa -w</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  REFERENCE &nbsp; &nbsp; &nbsp; &nbsp;  TARGETS &nbsp; MINPODS &nbsp; MAXPODS &nbsp; REPLICAS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">38</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  19m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">21</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  20m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">17</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  21m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; &nbsp;<span class="cm-number">7</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  22m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; &nbsp;<span class="cm-number">0</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp;  23m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; &nbsp;<span class="cm-number">0</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">2</span> &nbsp; &nbsp; &nbsp; &nbsp;  25m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; &nbsp;<span class="cm-number">0</span>%/50% &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp;  28m</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get horizontalpodautoscalers.autoscaling </span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp;  REFERENCE &nbsp; &nbsp; &nbsp; &nbsp;  TARGETS &nbsp; MINPODS &nbsp; MAXPODS &nbsp; REPLICAS &nbsp; AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb &nbsp; Deployment/myweb &nbsp; <span class="cm-number">0</span>%/50% &nbsp; &nbsp;<span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">3</span> &nbsp; &nbsp; &nbsp; &nbsp; <span class="cm-number">1</span> &nbsp; &nbsp; &nbsp; &nbsp;  5m41s</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">[root@master ~]<span class="cm-comment"># kubectl get pods</span></span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; READY &nbsp; &nbsp; STATUS &nbsp;  RESTARTS  AGE</span></pre><pre class=" CodeMirror-line " role="presentation"><span role="presentation" style="padding-right: 0.1px;">myweb-5946bb4c68-f9tw9 &nbsp; &nbsp; <span class="cm-number">1</span>/1 &nbsp; &nbsp; &nbsp; Running &nbsp; <span class="cm-number">0</span> &nbsp; &nbsp; &nbsp; &nbsp; 6m40s</span></pre></div></div></div></div></div><div style="position: absolute; height: 0px; width: 1px; border-bottom: 0px solid transparent; top: 855px;"></div><div class="CodeMirror-gutters" style="display: none; height: 855px;"></div></div></div></pre><h2 id='项目实战'><span>项目实战</span></h2><h3 id='项目1'><span>项目1</span></h3><blockquote><p><span>WEB集群项目1：</span><br/><span>使用 Apache 或 Nginx + PHP 搭建 web 集群</span><br/><span>使用 NFS 存放网页</span><br/><span>将访问日志存放在计算节点的 /var/weblog 目录下</span><br/><span>弹性部署后端服务</span></p></blockquote><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart6" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="456.34033203125" style="max-width: 865.583251953125px;" viewBox="0 0 865.583251953125 456.34033203125"><style>#mermaidChart6{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart6 .error-icon{fill:#552222;}#mermaidChart6 .error-text{fill:#552222;stroke:#552222;}#mermaidChart6 .edge-thickness-normal{stroke-width:2px;}#mermaidChart6 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart6 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart6 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart6 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart6 .marker{fill:#333333;}#mermaidChart6 .marker.cross{stroke:#333333;}#mermaidChart6 svg{font-family:sans-serif;font-size:16px;}#mermaidChart6 .label{font-family:sans-serif;color:#333;}#mermaidChart6 .label text{fill:#333;}#mermaidChart6 .node rect,#mermaidChart6 .node circle,#mermaidChart6 .node ellipse,#mermaidChart6 .node polygon,#mermaidChart6 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart6 .node .label{text-align:center;}#mermaidChart6 .node.clickable{cursor:pointer;}#mermaidChart6 .arrowheadPath{fill:#333333;}#mermaidChart6 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart6 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart6 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart6 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart6 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart6 .cluster text{fill:#333;}#mermaidChart6 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart6:root{--mermaid-font-family:sans-serif;}#mermaidChart6:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart6 .Kubernetes &gt; *{fill:#ffffc0 !important;color:#ff00ff !important;stroke-width:4px !important;}#mermaidChart6 .Kubernetes tspan{fill:#ff00ff !important;}#mermaidChart6 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;stroke-dasharray:0 !important;0 !important;}#mermaidChart6 .Pod tspan{fill:#000000 !important;}#mermaidChart6 .vPod &gt; *{fill:#aaeeaa !important;color:#000000 !important;stroke-width:3px !important;stroke:#f00000 !important;stroke-dasharray:10 !important;0 !important;}#mermaidChart6 .vPod tspan{fill:#000000 !important;}#mermaidChart6 .ELB &gt; *{fill:#ffaa00 !important;color:#3333ff !important;stroke:#303030 !important;stroke-width:3px !important;}#mermaidChart6 .ELB tspan{fill:#3333ff !important;}#mermaidChart6 .I &gt; *{fill:#009000 !important;color:#ffffff !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart6 .I tspan{fill:#ffffff !important;}#mermaidChart6 .NFS &gt; *{fill:#ccf !important;stroke:#f66 !important;stroke-width:2px !important;stroke-dasharray:0 !important;0 !important;}#mermaidChart6 .NFS tspan{!important;}#mermaidChart6 .User &gt; *{fill:#ccddee !important;color:#000000 !important;stroke:#555555 !important;stroke-width:3px !important;}#mermaidChart6 .User tspan{fill:#000000 !important;}#mermaidChart6 flowchart-v2{fill:apa;}</style><g transform="translate(0, 2)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"><g class="cluster Kubernetes" id="K"><rect rx="0" ry="0" x="167.12760162353516" y="8" width="472.7083282470703" height="438.34033203125"></rect><g class="cluster-label" transform="translate(360.07682037353516, 6)"><foreignObject width="86.80989074707031" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Kubernetes</span></div></foreignObject></g></g></g><g class="edgePaths"><path d="M271.4895782470703,227.170166015625L275.656244913737,227.170166015625C279.8229115804036,227.170166015625,288.156244913737,227.170166015625,296.4895782470703,227.170166015625C304.8229115804036,227.170166015625,313.156244913737,227.170166015625,321.4895782470703,227.170166015625C329.8229115804036,227.170166015625,338.156244913737,227.170166015625,346.4895782470703,227.170166015625C354.8229115804036,227.170166015625,363.156244913737,227.170166015625,367.3229115804036,227.170166015625L371.4895782470703,227.170166015625" id="L-I-ELB" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-I LE-ELB" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M430.75209004213895,189.76041408513095L438.85460501355004,172.7542431829216C446.9571199849611,155.7480722807123,463.1621499277833,121.73573047629365,475.43133156586106,104.72955957408432C487.7005132039388,87.723388671875,496.03384653727215,87.723388671875,504.36717987060547,87.723388671875C512.7005132039388,87.723388671875,521.0338465372721,87.723388671875,529.3671798706055,87.723388671875C537.7005132039388,87.723388671875,546.0338465372721,87.723388671875,550.2005132039388,87.723388671875L554.3671798706055,87.723388671875" id="L-ELB-Pod1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-ELB LE-Pod1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M454.36717987060547,227.170166015625L458.53384653727215,227.170166015625C462.7005132039388,227.170166015625,471.03384653727215,227.170166015625,479.36717987060547,227.170166015625C487.7005132039388,227.170166015625,496.03384653727215,227.170166015625,504.36717987060547,227.170166015625C512.7005132039388,227.170166015625,521.0338465372721,227.170166015625,529.3671798706055,227.170166015625C537.7005132039388,227.170166015625,546.0338465372721,227.170166015625,550.2005132039388,227.170166015625L554.3671798706055,227.170166015625" id="L-ELB-Pod2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-ELB LE-Pod2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M430.75209004213895,264.57991794611905L438.85460501355004,281.5860888483284C446.9571199849611,298.5922597505377,463.1621499277833,332.60460155495633,475.43133156586106,349.6107724571657C487.7005132039388,366.616943359375,496.03384653727215,366.616943359375,504.36717987060547,366.616943359375C512.7005132039388,366.616943359375,521.0338465372721,366.616943359375,529.3671798706055,366.616943359375C537.7005132039388,366.616943359375,546.0338465372721,366.616943359375,550.2005132039388,366.616943359375L554.3671798706055,366.616943359375" id="L-ELB-Pod3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-ELB LE-Pod3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M67.12760162353516,227.170166015625L71.29426829020183,227.170166015625C75.46093495686848,227.170166015625,83.79426829020183,227.170166015625,92.12760162353516,227.170166015625C100.46093495686848,227.170166015625,108.79426829020183,227.170166015625,117.12760162353516,227.170166015625C125.46093495686848,227.170166015625,133.7942682902018,227.170166015625,142.12760162353516,227.170166015625C150.4609349568685,227.170166015625,158.7942682902018,227.170166015625,167.12760162353516,227.170166015625C175.4609349568685,227.170166015625,183.7942682902018,227.170166015625,187.9609349568685,227.170166015625L192.12760162353516,227.170166015625" id="L-User-I" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-User LE-I" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-end="url(#flowchart-pointEnd)"></path><path d="M614.8359298706055,87.723388671875L619.0025965372721,87.723388671875C623.1692632039388,87.723388671875,631.5025965372721,87.723388671875,639.8359298706055,87.723388671875C648.1692632039388,87.723388671875,656.5025965372721,87.723388671875,664.8359298706055,87.723388671875C673.1692632039388,87.723388671875,681.5025965372721,87.723388671875,689.8359298706055,87.723388671875C698.1692632039388,87.723388671875,706.5025965372721,87.723388671875,721.0462930803611,104.92082200396902C735.5899896234504,122.11825533606304,756.3440493762952,156.51312200025106,766.7210792527176,173.71055533234508L777.09810912914,190.9079886644391" id="L-Pod1-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-Pod1 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M614.8359298706055,227.170166015625L619.0025965372721,227.170166015625C623.1692632039388,227.170166015625,631.5025965372721,227.170166015625,639.8359298706055,227.170166015625C648.1692632039388,227.170166015625,656.5025965372721,227.170166015625,664.8359298706055,227.170166015625C673.1692632039388,227.170166015625,681.5025965372721,227.170166015625,689.8359298706055,227.170166015625C698.1692632039388,227.170166015625,706.5025965372721,227.170166015625,714.9192635218302,227.25349934895834C723.3359305063883,227.33683268229166,731.8359311421713,227.50349934895834,736.0859314600625,227.58683268229166L740.335931777954,227.67016601562503" id="L-Pod2-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-Pod2 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M614.8359298706055,366.616943359375L619.0025965372721,366.616943359375C623.1692632039388,366.616943359375,631.5025965372721,366.616943359375,639.8359298706055,366.616943359375C648.1692632039388,366.616943359375,656.5025965372721,366.616943359375,664.8359298706055,366.616943359375C673.1692632039388,366.616943359375,681.5025965372721,366.616943359375,689.8359298706055,366.616943359375C698.1692632039388,366.616943359375,706.5025965372721,366.616943359375,721.0462928415768,349.586177090946C735.5899891458813,332.5554108225171,756.3440484211573,298.49387828565915,766.7210780587952,281.46311201723023L777.0981076964332,264.43234574880125" id="L-Pod3-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-Pod3 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default Pod" id="flowchart-Pod1-97" label-offset-y="8.150800336983993" transform="translate(584.6015548706055, 87.723388671875)"><path d="M 0,8.150800336983993 a 30.234375,8.150800336983993 0,0,0 60.46875 0 a 30.234375,8.150800336983993 0,0,0 -60.46875 0 l 0,73.15080033698399 a 30.234375,8.150800336983993 0,0,0 60.46875 0 l 0,-73.15080033698399" transform="translate(-30.234375,-44.72620050547599)"></path><g class="label" style="" transform="translate(-22.734375, -25)"><foreignObject width="45.46875" height="50"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Nginx<br>PHP</span></div></foreignObject></g></g><g class="node default vPod" id="flowchart-Pod2-98" label-offset-y="8.150800336983993" transform="translate(584.6015548706055, 227.170166015625)"><path d="M 0,8.150800336983993 a 30.234375,8.150800336983993 0,0,0 60.46875 0 a 30.234375,8.150800336983993 0,0,0 -60.46875 0 l 0,73.15080033698399 a 30.234375,8.150800336983993 0,0,0 60.46875 0 l 0,-73.15080033698399" transform="translate(-30.234375,-44.72620050547599)"></path><g class="label" style="" transform="translate(-22.734375, -25)"><foreignObject width="45.46875" height="50"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Nginx<br>PHP</span></div></foreignObject></g></g><g class="node default vPod" id="flowchart-Pod3-99" label-offset-y="8.150800336983993" transform="translate(584.6015548706055, 366.616943359375)"><path d="M 0,8.150800336983993 a 30.234375,8.150800336983993 0,0,0 60.46875 0 a 30.234375,8.150800336983993 0,0,0 -60.46875 0 l 0,73.15080033698399 a 30.234375,8.150800336983993 0,0,0 60.46875 0 l 0,-73.15080033698399" transform="translate(-30.234375,-44.72620050547599)"></path><g class="label" style="" transform="translate(-22.734375, -25)"><foreignObject width="45.46875" height="50"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Nginx<br>PHP</span></div></foreignObject></g></g><g class="node default ELB" id="flowchart-ELB-101" transform="translate(412.9283790588379, 227.170166015625)"><circle rx="0" ry="0" r="41.43880081176758" width="82.87760162353516" height="40"></circle><g class="label" style="" transform="translate(-33.93880081176758, -12.5)"><foreignObject width="67.87760162353516" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>ClusterIP</span></div></foreignObject></g></g><g class="node default I" id="flowchart-I-100" transform="translate(231.80858993530273, 227.170166015625)"><rect rx="20" ry="20" x="-39.68098831176758" y="-20" width="79.36197662353516" height="40"></rect><g class="label" style="" transform="translate(-27.180988311767578, -12.5)"><foreignObject width="54.361976623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>ingress</span></div></foreignObject></g></g><g class="node default User" id="flowchart-User-105" transform="translate(37.56380081176758, 227.170166015625)"><circle rx="0" ry="0" r="29.563800811767578" width="59.127601623535156" height="40"></circle><g class="label" style="" transform="translate(-22.063800811767578, -12.5)"><foreignObject width="44.127601623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Client</span></div></foreignObject></g></g><g class="node default NFS" id="flowchart-NFS-110" transform="translate(798.7096252441406, 227.170166015625)"><polygon points="58.87369728088379,0 117.74739456176758,-58.87369728088379 58.87369728088379,-117.74739456176758 0,-58.87369728088379" class="label-container" transform="translate(-58.87369728088379,58.87369728088379)"></polygon><g class="label" style="" transform="translate(-31.37369728088379, -12.5)"><foreignObject width="62.74739456176758" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>NFS存储</span></div></foreignObject></g></g></g></g></g></svg></div><h3 id='项目2'><span>项目2</span></h3><blockquote><p><span>WEB集群项目2：</span><br/><span>使用 Nginx 搭建 web 集群，动态页面由 PHP 和 Tomcat 集群解析</span><br/><span>使用 NFS 存放网页</span><br/><span>将访问日志存放在计算节点的 /var/weblog 目录下</span><br/><span>弹性部署 PHP、Tomcat 集群服务</span></p></blockquote><div class="md-diagram-panel md-fences-adv-panel"><svg id="mermaidChart7" width="100%" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="856.9325561523438" style="max-width: 1068.9296875px;" viewBox="0 0 1068.9296875 856.9325561523438"><style>#mermaidChart7{font-family:sans-serif;font-size:16px;fill:#333;}#mermaidChart7 .error-icon{fill:#552222;}#mermaidChart7 .error-text{fill:#552222;stroke:#552222;}#mermaidChart7 .edge-thickness-normal{stroke-width:2px;}#mermaidChart7 .edge-thickness-thick{stroke-width:3.5px;}#mermaidChart7 .edge-pattern-solid{stroke-dasharray:0;}#mermaidChart7 .edge-pattern-dashed{stroke-dasharray:3;}#mermaidChart7 .edge-pattern-dotted{stroke-dasharray:2;}#mermaidChart7 .marker{fill:#333333;}#mermaidChart7 .marker.cross{stroke:#333333;}#mermaidChart7 svg{font-family:sans-serif;font-size:16px;}#mermaidChart7 .label{font-family:sans-serif;color:#333;}#mermaidChart7 .label text{fill:#333;}#mermaidChart7 .node rect,#mermaidChart7 .node circle,#mermaidChart7 .node ellipse,#mermaidChart7 .node polygon,#mermaidChart7 .node path{fill:#ECECFF;stroke:#9370DB;stroke-width:1px;}#mermaidChart7 .node .label{text-align:center;}#mermaidChart7 .node.clickable{cursor:pointer;}#mermaidChart7 .arrowheadPath{fill:#333333;}#mermaidChart7 .edgePath .path{stroke:#333333;stroke-width:1.5px;}#mermaidChart7 .flowchart-link{stroke:#333333;fill:none;}#mermaidChart7 .edgeLabel{background-color:#e8e8e8;text-align:center;}#mermaidChart7 .edgeLabel rect{opacity:0.5;background-color:#e8e8e8;fill:#e8e8e8;}#mermaidChart7 .cluster rect{fill:#ffffde;stroke:#aaaa33;stroke-width:1px;}#mermaidChart7 .cluster text{fill:#333;}#mermaidChart7 div.mermaidTooltip{position:absolute;text-align:center;max-width:200px;padding:2px;font-family:sans-serif;font-size:12px;background:hsl(80,100%,96.2745098039%);border:1px solid #aaaa33;border-radius:2px;pointer-events:none;z-index:100;}#mermaidChart7:root{--mermaid-font-family:sans-serif;}#mermaidChart7:root{--mermaid-alt-font-family:sans-serif;}#mermaidChart7 .I &gt; *{fill:#009000 !important;color:#ffffff !important;stroke:#f06080 !important;stroke-width:3px !important;}#mermaidChart7 .I tspan{fill:#ffffff !important;}#mermaidChart7 .NFS &gt; *{fill:#ccf !important;stroke:#f66 !important;stroke-width:3px !important;stroke-dasharray:0 !important;0 !important;}#mermaidChart7 .NFS tspan{!important;}#mermaidChart7 .User &gt; *{fill:#ccddee !important;color:#000000 !important;stroke:#555555 !important;stroke-width:3px !important;}#mermaidChart7 .User tspan{fill:#000000 !important;}#mermaidChart7 .S &gt; *{fill:#ffaa00 !important;color:#3333ff !important;stroke:#303030 !important;stroke-width:3px !important;}#mermaidChart7 .S tspan{fill:#3333ff !important;}#mermaidChart7 .Pod &gt; *{fill:#ccffbb !important;color:#000000 !important;stroke-width:3px !important;stroke-dasharray:0 !important;0 !important;}#mermaidChart7 .Pod tspan{fill:#000000 !important;}#mermaidChart7 .vPod &gt; *{fill:#aaeeaa !important;color:#000000 !important;stroke-width:3px !important;stroke:#f00000 !important;stroke-dasharray:10 !important;0 !important;}#mermaidChart7 .vPod tspan{fill:#000000 !important;}#mermaidChart7 .Kubernetes &gt; *{fill:#ffffc0 !important;color:#ff00ff !important;stroke-width:4px !important;}#mermaidChart7 .Kubernetes tspan{fill:#ff00ff !important;}#mermaidChart7 flowchart-v2{fill:apa;}</style><g transform="translate(0, 2)"><marker id="flowchart-pointEnd" class="marker flowchart" viewBox="0 0 10 10" refX="9" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 0 L 10 5 L 0 10 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-pointStart" class="marker flowchart" viewBox="0 0 10 10" refX="0" refY="5" markerUnits="userSpaceOnUse" markerWidth="12" markerHeight="12" orient="auto"><path d="M 0 5 L 10 10 L 10 0 z" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-circleEnd" class="marker flowchart" viewBox="0 0 10 10" refX="11" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-circleStart" class="marker flowchart" viewBox="0 0 10 10" refX="-1" refY="5" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><circle cx="5" cy="5" r="5" class="arrowMarkerPath" style="stroke-width: 1; stroke-dasharray: 1, 0;"></circle></marker><marker id="flowchart-crossEnd" class="marker cross flowchart" viewBox="0 0 11 11" refX="12" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><marker id="flowchart-crossStart" class="marker cross flowchart" viewBox="0 0 11 11" refX="-1" refY="5.2" markerUnits="userSpaceOnUse" markerWidth="11" markerHeight="11" orient="auto"><path d="M 1,1 l 9,9 M 10,1 l -9,9" class="arrowMarkerPath" style="stroke-width: 2; stroke-dasharray: 1, 0;"></path></marker><g class="root"><g class="clusters"><g class="cluster Kubernetes" id="K"><rect rx="0" ry="0" x="117.12760162353516" y="8" width="775.3124923706055" height="838.9325866699219"></rect><g class="cluster-label" transform="translate(461.37890243530273, 6)"><foreignObject width="86.80989074707031" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Kubernetes</span></div></foreignObject></g></g></g><g class="edgePaths"><path d="M188.4426290782368,412.46629333496094L198.1171206063757,383.30007553100586C207.79161213451462,354.1338577270508,227.14059519079248,295.8014221191406,242.9544102713809,266.63520431518555C258.7682253519694,237.46898651123047,271.04687245686847,237.46898651123047,277.18619600931805,237.46898651123047L283.3255195617676,237.46898651123047" id="L-I-WS1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-I LE-WS1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M188.7319274440318,452.46629333496094L198.35820257787157,480.27448590596515C207.98447771171132,508.0826784769694,227.23702797939083,563.6990636189779,241.02996977989721,591.5072561899821C254.82291158040366,619.3154487609863,263.156244913737,619.3154487609863,267.3229115804036,619.3154487609863L271.4895782470703,619.3154487609863" id="L-I-WS2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-I LE-WS2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M357.181369567951,204.96898651123047L369.4749251811375,183.3315315246582C381.76848079432403,161.69407653808594,406.3555920206972,118.4191665649414,422.81581430055047,96.78171157836914C439.2760365804036,75.14425659179688,447.609369913737,75.14425659179688,455.9427032470703,75.14425659179688C464.2760365804036,75.14425659179688,472.609369913737,75.14425659179688,480.9427032470703,75.14425659179688C489.2760365804036,75.14425659179688,497.609369913737,75.14425659179688,501.7760365804036,75.14425659179688L505.9427032470703,75.14425659179688" id="L-WS1-WEB1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-WS1 LE-WEB1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M361.7620309531401,269.96898651123047L373.2921430021285,286.22909355163574C384.8222550511168,302.489200592041,407.88247914909357,335.00941467285156,423.5792578647486,351.26952171325684C439.2760365804036,367.5296287536621,447.609369913737,367.5296287536621,455.9427032470703,367.5296287536621C464.2760365804036,367.5296287536621,472.609369913737,367.5296287536621,480.9427032470703,367.5296287536621C489.2760365804036,367.5296287536621,497.609369913737,367.5296287536621,501.7760365804036,367.5296287536621L505.9427032470703,367.5296287536621" id="L-WS1-WEB2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-WS1 LE-WEB2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M563.2734298706055,93.17182506555795L567.4400965372721,95.79223031993111C571.6067632039388,98.41263557430426,579.9400965372721,103.65344608305058,592.5260586254518,122.28630632399599C605.1120207136314,140.9191665649414,621.9506115566572,172.94407653808594,630.3699069781702,188.9565315246582L638.7892023996832,204.96898651123047" id="L-WEB1-PS1" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB1 LE-PS1" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-end="url(#flowchart-pointEnd)"></path><path d="M563.2734298706055,348.89838035402306L567.4400965372721,346.19022693483043C571.6067632039388,343.48207351563775,579.9400965372721,338.0657666772525,591.5268093157009,324.91086770345373C603.1135220941296,311.75596872965497,617.9536143176537,290.8624776204427,625.3736604294157,280.4157320658366L632.7937065411778,269.96898651123047" id="L-WEB2-PS1" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB2 LE-PS1" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-end="url(#flowchart-pointEnd)"></path><path d="M360.40335183042896,586.8154487609863L372.1599103998692,569.1973164876302C383.9164689693094,551.579184214274,407.4295861081899,516.3429196675619,423.35281134429675,498.72478739420575C439.2760365804036,481.1066551208496,447.609369913737,481.1066551208496,455.9427032470703,481.1066551208496C464.2760365804036,481.1066551208496,472.609369913737,481.1066551208496,480.9427032470703,481.1066551208496C489.2760365804036,481.1066551208496,497.609369913737,481.1066551208496,501.7760365804036,481.1066551208496L505.9427032470703,481.1066551208496" id="L-WS2-WEB3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-WS2 LE-WEB3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M357.39445733644084,651.8154487609863L369.6524983215457,673.1442623138428C381.91053930665066,694.4730758666992,406.4266212768605,737.1307029724121,422.85132892863203,758.4595165252686C439.2760365804036,779.788330078125,447.609369913737,779.788330078125,455.9427032470703,779.788330078125C464.2760365804036,779.788330078125,472.609369913737,779.788330078125,480.9427032470703,779.788330078125C489.2760365804036,779.788330078125,497.609369913737,779.788330078125,501.7760365804036,779.788330078125L505.9427032470703,779.788330078125" id="L-WS2-WEB4" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-WS2 LE-WEB4" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M563.2734298706055,499.35654640826397L567.4400965372721,502.0092674943541C571.6067632039388,504.6619885804442,579.9400965372721,509.96743075262447,591.8158627126805,524.3555529922791C603.691628888089,538.7436752319336,619.1098279055725,562.2144775390625,626.8189274143143,573.949878692627L634.528026923056,585.6852798461914" id="L-WEB3-PS2" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB3 LE-PS2" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-end="url(#flowchart-pointEnd)"></path><path d="M563.2734298706055,761.5384387907106L567.4400965372721,758.8857177046206C571.6067632039388,756.2329966185304,579.9400965372721,750.9275544463502,592.5006279374816,732.4520279555969C605.0611593376909,713.9765014648438,621.8488888047764,682.3308906555176,630.2427535383191,666.5080852508545L638.6366182718618,650.6852798461914" id="L-WEB4-PS2" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB4 LE-PS2" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-end="url(#flowchart-pointEnd)"></path><path d="M675.7648927907634,204.96898651123047L683.7177036785821,191.9724324544271C691.6705145664009,178.9758783976237,707.5761363420384,152.98277028401694,719.6956138965237,139.98621622721353C731.8150914510092,126.98966217041016,740.1484247843424,126.98966217041016,748.4817581176758,126.98966217041016C756.8150914510092,126.98966217041016,765.1484247843424,126.98966217041016,775.3155256907145,126.98966217041016C785.4826265970866,126.98966217041016,797.4834950764974,126.98966217041016,803.4839293162028,126.98966217041016L809.4843635559082,126.98966217041016" id="L-PS1-PHP1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-PS1 LE-PHP1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M697.6809768676758,237.46898651123047L701.9811070760092,237.46898651123047C706.2812372843424,237.46898651123047,714.8814977010092,237.46898651123047,723.3482945760092,237.46898651123047C731.8150914510092,237.46898651123047,740.1484247843424,237.46898651123047,748.4817581176758,237.46898651123047C756.8150914510092,237.46898651123047,765.1484247843424,237.46898651123047,775.3155256907145,237.46898651123047C785.4826265970866,237.46898651123047,797.4834950764974,237.46898651123047,803.4839293162028,237.46898651123047L809.4843635559082,237.46898651123047" id="L-PS1-PHP2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-PS1 LE-PHP2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M675.7648927907634,269.96898651123047L683.7177036785821,282.9655405680339C691.6705145664009,295.9620946248372,707.5761363420384,321.95520273844403,719.6956138965237,334.9517567952474C731.8150914510092,347.9483108520508,740.1484247843424,347.9483108520508,748.4817581176758,347.9483108520508C756.8150914510092,347.9483108520508,765.1484247843424,347.9483108520508,775.3155256907145,347.9483108520508C785.4826265970866,347.9483108520508,797.4834950764974,347.9483108520508,803.4839293162028,347.9483108520508L809.4843635559082,347.9483108520508" id="L-PS1-PHP3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-PS1 LE-PHP3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M674.7104724014752,585.6852798461914L682.839020020842,571.6578013102213C690.9675676402088,557.6303227742513,707.2246628789422,529.5753657023112,719.5198771649757,515.5478871663412C731.8150914510092,501.5204086303711,740.1484247843424,501.5204086303711,748.4817581176758,501.5204086303711C756.8150914510092,501.5204086303711,765.1484247843424,501.5204086303711,773.4817581176758,501.5204086303711C781.8150914510092,501.5204086303711,790.1484247843424,501.5204086303711,794.3150914510092,501.5204086303711L798.4817581176758,501.5204086303711" id="L-PS2-TM1" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-PS2 LE-TM1" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M698.4817581176758,618.1852798461914L702.6484247843424,618.1852798461914C706.8150914510092,618.1852798461914,715.1484247843424,618.1852798461914,723.4817581176758,618.1852798461914C731.8150914510092,618.1852798461914,740.1484247843424,618.1852798461914,748.4817581176758,618.1852798461914C756.8150914510092,618.1852798461914,765.1484247843424,618.1852798461914,773.4817581176758,618.1852798461914C781.8150914510092,618.1852798461914,790.1484247843424,618.1852798461914,794.3150914510092,618.1852798461914L798.4817581176758,618.1852798461914" id="L-PS2-TM2" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-PS2 LE-TM2" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M674.7104724014752,650.6852798461914L682.839020020842,664.7127583821615C690.9675676402088,678.7402369181315,707.2246628789422,706.7951939900717,719.5198771649757,720.8226725260416C731.8150914510092,734.8501510620117,740.1484247843424,734.8501510620117,748.4817581176758,734.8501510620117C756.8150914510092,734.8501510620117,765.1484247843424,734.8501510620117,773.4817581176758,734.8501510620117C781.8150914510092,734.8501510620117,790.1484247843424,734.8501510620117,794.3150914510092,734.8501510620117L798.4817581176758,734.8501510620117" id="L-PS2-TM3" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-PS2 LE-TM3" style="fill:none;" marker-end="url(#flowchart-pointEnd)"></path><path d="M563.2734298706055,67.98971206250076L567.4400965372721,66.94976005208396C571.6067632039388,65.90980804166718,579.9400965372721,63.82990402083359,595.3741238911947,62.78995201041679C610.8081512451172,61.75,633.3428726196289,61.75,655.8775939941406,61.75C678.4123153686523,61.75,700.9470367431641,61.75,716.3810640970866,61.75C731.8150914510092,61.75,740.1484247843424,61.75,748.4817581176758,61.75C756.8150914510092,61.75,765.1484247843424,61.75,779.2282861073812,61.75C793.3081474304199,61.75,813.1345367431641,61.75,832.9609260559082,61.75C852.7873153686523,61.75,872.6137046813965,61.75,886.6935660044352,61.75C900.773427327474,61.75,909.1067606608073,61.75,927.3142255147299,122.1780236562093C945.5216903686523,182.6060473124186,973.6032867431641,303.4620946248372,987.6440849304199,363.89011828104657L1001.6848831176758,424.31814193725586" id="L-WEB1-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB1 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M856.4374885559082,126.98966217041016L862.4379227956136,126.98966217041016C868.438357035319,126.98966217041016,880.4392255147299,126.98966217041016,890.6063264211019,126.98966217041016C900.773427327474,126.98966217041016,909.1067606608073,126.98966217041016,927.3142255147299,176.54440879821777C945.5216903686523,226.0991554260254,973.6032867431641,325.2086486816406,987.6440849304199,374.76339530944824L1001.6848831176758,424.31814193725586" id="L-PHP1-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-PHP1 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M856.4374885559082,237.46898651123047L862.4379227956136,237.46898651123047C868.438357035319,237.46898651123047,880.4392255147299,237.46898651123047,890.6063264211019,237.46898651123047C900.773427327474,237.46898651123047,909.1067606608073,237.46898651123047,927.3142255147299,268.61051241556805C945.5216903686523,299.7520383199056,973.6032867431641,362.03509012858075,987.6440849304199,393.1766160329183L1001.6848831176758,424.31814193725586" id="L-PHP2-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-PHP2 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M856.4374885559082,347.9483108520508L862.4379227956136,347.9483108520508C868.438357035319,347.9483108520508,880.4392255147299,347.9483108520508,890.6063264211019,347.9483108520508C900.773427327474,347.9483108520508,909.1067606608073,347.9483108520508,927.3142255147299,360.6766160329183C945.5216903686523,373.4049212137858,973.6032867431641,398.8615315755208,987.6440849304199,411.58983675638837L1001.6848831176758,424.31814193725586" id="L-PHP3-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-PHP3 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M563.2734298706055,384.0572261259114L567.4400965372721,388.91235060866967C571.6067632039388,393.76747509142797,579.9400965372721,403.47772405694445,595.3741238911947,408.33284853970264C610.8081512451172,413.18797302246094,633.3428726196289,413.18797302246094,655.8775939941406,413.18797302246094C678.4123153686523,413.18797302246094,700.9470367431641,413.18797302246094,716.3810640970866,413.18797302246094C731.8150914510092,413.18797302246094,740.1484247843424,413.18797302246094,748.4817581176758,413.18797302246094C756.8150914510092,413.18797302246094,765.1484247843424,413.18797302246094,779.2282861073812,413.18797302246094C793.3081474304199,413.18797302246094,813.1345367431641,413.18797302246094,832.9609260559082,413.18797302246094C852.7873153686523,413.18797302246094,872.6137046813965,413.18797302246094,886.6935660044352,413.18797302246094C900.773427327474,413.18797302246094,909.1067606608073,413.18797302246094,927.3142255147299,415.04300117492676C945.5216903686523,416.8980293273926,973.6032867431641,420.6080856323242,987.6440849304199,422.46311378479004L1001.6848831176758,424.31814193725586" id="L-WEB2-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB2 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M563.2734298706055,463.37169789684435L567.4400965372721,458.3410770844471C571.6067632039388,453.31045627204986,579.9400965372721,443.2492146472554,595.3741238911947,438.21859383485815C610.8081512451172,433.18797302246094,633.3428726196289,433.18797302246094,655.8775939941406,433.18797302246094C678.4123153686523,433.18797302246094,700.9470367431641,433.18797302246094,716.3810640970866,433.18797302246094C731.8150914510092,433.18797302246094,740.1484247843424,433.18797302246094,748.4817581176758,433.18797302246094C756.8150914510092,433.18797302246094,765.1484247843424,433.18797302246094,779.2282861073812,433.18797302246094C793.3081474304199,433.18797302246094,813.1345367431641,433.18797302246094,832.9609260559082,433.18797302246094C852.7873153686523,433.18797302246094,872.6137046813965,433.18797302246094,886.6935660044352,433.18797302246094C900.773427327474,433.18797302246094,909.1067606608073,433.18797302246094,927.3142255147299,431.70966784159344C945.5216903686523,430.2313626607259,973.6032867431641,427.2747522989909,987.6440849304199,425.79644711812335L1001.6848831176758,424.31814193725586" id="L-WEB3-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB3 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M867.4400939941406,501.5204086303711L871.6067606608073,501.5204086303711C875.773427327474,501.5204086303711,884.1067606608073,501.5204086303711,892.4400939941406,501.5204086303711C900.773427327474,501.5204086303711,909.1067606608073,501.5204086303711,927.3142255147299,488.65336418151855C945.5216903686523,475.786319732666,973.6032867431641,450.05223083496094,987.6440849304199,437.1851863861084L1001.6848831176758,424.31814193725586" id="L-TM1-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-TM1 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M867.4400939941406,618.1852798461914L871.6067606608073,618.1852798461914C875.773427327474,618.1852798461914,884.1067606608073,618.1852798461914,892.4400939941406,618.1852798461914C900.773427327474,618.1852798461914,909.1067606608073,618.1852798461914,927.3142255147299,585.8740901947021C945.5216903686523,553.5629005432129,973.6032867431641,488.9405212402344,987.6440849304199,456.6293315887451L1001.6848831176758,424.31814193725586" id="L-TM2-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-TM2 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M867.4400939941406,734.8501510620117L871.6067606608073,734.8501510620117C875.773427327474,734.8501510620117,884.1067606608073,734.8501510620117,892.4400939941406,734.8501510620117C900.773427327474,734.8501510620117,909.1067606608073,734.8501510620117,927.3142255147299,683.0948162078857C945.5216903686523,631.3394813537598,973.6032867431641,527.8288116455078,987.6440849304199,476.07347679138184L1001.6848831176758,424.31814193725586" id="L-TM3-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-TM3 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M563.2734298706055,792.2843763774245L567.4400965372721,794.1007447595074C571.6067632039388,795.9171131415902,579.9400965372721,799.5498499057561,595.3741238911947,801.3662182878389C610.8081512451172,803.1825866699219,633.3428726196289,803.1825866699219,655.8775939941406,803.1825866699219C678.4123153686523,803.1825866699219,700.9470367431641,803.1825866699219,716.3810640970866,803.1825866699219C731.8150914510092,803.1825866699219,740.1484247843424,803.1825866699219,748.4817581176758,803.1825866699219C756.8150914510092,803.1825866699219,765.1484247843424,803.1825866699219,779.2282861073812,803.1825866699219C793.3081474304199,803.1825866699219,813.1345367431641,803.1825866699219,832.9609260559082,803.1825866699219C852.7873153686523,803.1825866699219,872.6137046813965,803.1825866699219,886.6935660044352,803.1825866699219C900.773427327474,803.1825866699219,909.1067606608073,803.1825866699219,927.3142255147299,740.0385125478109C945.5216903686523,676.8944384256998,973.6032867431641,550.6062901814779,987.6440849304199,487.4622160593669L1001.6848831176758,424.31814193725586" id="L-WEB4-NFS" class=" edge-thickness-normal edge-pattern-dotted flowchart-link LS-WEB4 LE-NFS" style="fill:none;stroke-width:2px;stroke-dasharray:3;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path><path d="M67.12760162353516,432.46629333496094L71.29426829020183,432.46629333496094C75.46093495686848,432.46629333496094,83.79426829020183,432.46629333496094,92.12760162353516,432.46629333496094C100.46093495686848,432.46629333496094,108.79426829020183,432.46629333496094,117.12760162353516,432.46629333496094C125.46093495686848,432.46629333496094,133.7942682902018,432.46629333496094,137.9609349568685,432.46629333496094L142.12760162353516,432.46629333496094" id="L-U-I" class=" edge-thickness-normal edge-pattern-solid flowchart-link LS-U LE-I" style="fill:none;" marker-start="url(#flowchart-circleStart)" marker-end="url(#flowchart-circleEnd)"></path></g><g class="edgeLabels"><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g><g class="edgeLabel"><g class="label" transform="translate(0, 0)"><foreignObject width="0" height="0"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span></span></div></foreignObject></g></g></g><g class="nodes"><g class="node default S" id="flowchart-WS1-146" transform="translate(338.7161407470703, 237.46898651123047)"><rect rx="32.5" ry="32.5" x="-55.390625" y="-32.5" width="110.78125" height="65"></rect><g class="label" style="" transform="translate(-39.765625, -25)"><foreignObject width="79.53125" height="50"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>nginx-php<br>service</span></div></foreignObject></g></g><g class="node default S" id="flowchart-WS2-147" transform="translate(338.7161407470703, 619.3154487609863)"><rect rx="32.5" ry="32.5" x="-67.2265625" y="-32.5" width="134.453125" height="65"></rect><g class="label" style="" transform="translate(-51.6015625, -25)"><foreignObject width="103.203125" height="50"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>nginx-tomcat<br>service</span></div></foreignObject></g></g><g class="node default I" id="flowchart-I-148" transform="translate(181.80858993530273, 432.46629333496094)"><rect rx="20" ry="20" x="-39.68098831176758" y="-20" width="79.36197662353516" height="40"></rect><g class="label" style="" transform="translate(-27.180988311767578, -12.5)"><foreignObject width="54.361976623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>ingress</span></div></foreignObject></g></g><g class="node default S" id="flowchart-PS1-154" transform="translate(655.8775939941406, 237.46898651123047)"><rect rx="32.5" ry="32.5" x="-41.80338478088379" y="-32.5" width="83.60676956176758" height="65"></rect><g class="label" style="" transform="translate(-26.17838478088379, -25)"><foreignObject width="52.35676956176758" height="50"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>php<br>service</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-WEB1-152" label-offset-y="7.860815300471541" transform="translate(534.6080665588379, 75.14425659179688)"><path d="M 0,7.860815300471541 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 a 28.665363311767578,7.860815300471541 0,0,0 -57.330726623535156 0 l 0,47.86081530047154 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 l 0,-47.86081530047154" transform="translate(-28.665363311767578,-31.79122295070731)"></path><g class="label" style="" transform="translate(-21.165363311767578, -12.5)"><foreignObject width="42.330726623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>nginx</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-WEB2-153" label-offset-y="7.860815300471541" transform="translate(534.6080665588379, 367.5296287536621)"><path d="M 0,7.860815300471541 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 a 28.665363311767578,7.860815300471541 0,0,0 -57.330726623535156 0 l 0,47.86081530047154 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 l 0,-47.86081530047154" transform="translate(-28.665363311767578,-31.79122295070731)"></path><g class="label" style="" transform="translate(-21.165363311767578, -12.5)"><foreignObject width="42.330726623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>nginx</span></div></foreignObject></g></g><g class="node default S" id="flowchart-PS2-158" transform="translate(655.8775939941406, 618.1852798461914)"><rect rx="32.5" ry="32.5" x="-42.60416603088379" y="-32.5" width="85.20833206176758" height="65"></rect><g class="label" style="" transform="translate(-26.97916603088379, -25)"><foreignObject width="53.95833206176758" height="50"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>tomcat<br>service</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-WEB3-156" label-offset-y="7.860815300471541" transform="translate(534.6080665588379, 481.1066551208496)"><path d="M 0,7.860815300471541 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 a 28.665363311767578,7.860815300471541 0,0,0 -57.330726623535156 0 l 0,47.86081530047154 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 l 0,-47.86081530047154" transform="translate(-28.665363311767578,-31.79122295070731)"></path><g class="label" style="" transform="translate(-21.165363311767578, -12.5)"><foreignObject width="42.330726623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>nginx</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-WEB4-157" label-offset-y="7.860815300471541" transform="translate(534.6080665588379, 779.788330078125)"><path d="M 0,7.860815300471541 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 a 28.665363311767578,7.860815300471541 0,0,0 -57.330726623535156 0 l 0,47.86081530047154 a 28.665363311767578,7.860815300471541 0,0,0 57.330726623535156 0 l 0,-47.86081530047154" transform="translate(-28.665363311767578,-31.79122295070731)"></path><g class="label" style="" transform="translate(-21.165363311767578, -12.5)"><foreignObject width="42.330726623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>nginx</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-PHP1-160" label-offset-y="6.826442526124489" transform="translate(832.9609260559082, 126.98966217041016)"><path d="M 0,6.826442526124489 a 23.4765625,6.826442526124489 0,0,0 46.953125 0 a 23.4765625,6.826442526124489 0,0,0 -46.953125 0 l 0,46.82644252612449 a 23.4765625,6.826442526124489 0,0,0 46.953125 0 l 0,-46.82644252612449" transform="translate(-23.4765625,-30.239663789186732)"></path><g class="label" style="" transform="translate(-15.9765625, -12.5)"><foreignObject width="31.953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>PHP</span></div></foreignObject></g></g><g class="node default vPod" id="flowchart-PHP2-161" label-offset-y="6.826442526124489" transform="translate(832.9609260559082, 237.46898651123047)"><path d="M 0,6.826442526124489 a 23.4765625,6.826442526124489 0,0,0 46.953125 0 a 23.4765625,6.826442526124489 0,0,0 -46.953125 0 l 0,46.82644252612449 a 23.4765625,6.826442526124489 0,0,0 46.953125 0 l 0,-46.82644252612449" transform="translate(-23.4765625,-30.239663789186732)"></path><g class="label" style="" transform="translate(-15.9765625, -12.5)"><foreignObject width="31.953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>PHP</span></div></foreignObject></g></g><g class="node default vPod" id="flowchart-PHP3-162" label-offset-y="6.826442526124489" transform="translate(832.9609260559082, 347.9483108520508)"><path d="M 0,6.826442526124489 a 23.4765625,6.826442526124489 0,0,0 46.953125 0 a 23.4765625,6.826442526124489 0,0,0 -46.953125 0 l 0,46.82644252612449 a 23.4765625,6.826442526124489 0,0,0 46.953125 0 l 0,-46.82644252612449" transform="translate(-23.4765625,-30.239663789186732)"></path><g class="label" style="" transform="translate(-15.9765625, -12.5)"><foreignObject width="31.953125" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>PHP</span></div></foreignObject></g></g><g class="node default Pod" id="flowchart-TM1-164" label-offset-y="8.888292053342576" transform="translate(832.9609260559082, 501.5204086303711)"><path d="M 0,8.888292053342576 a 34.47916603088379,8.888292053342576 0,0,0 68.95833206176758 0 a 34.47916603088379,8.888292053342576 0,0,0 -68.95833206176758 0 l 0,48.888292053342575 a 34.47916603088379,8.888292053342576 0,0,0 68.95833206176758 0 l 0,-48.888292053342575" transform="translate(-34.47916603088379,-33.332438080013866)"></path><g class="label" style="" transform="translate(-26.97916603088379, -12.5)"><foreignObject width="53.95833206176758" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>tomcat</span></div></foreignObject></g></g><g class="node default vPod" id="flowchart-TM2-165" label-offset-y="8.888292053342576" transform="translate(832.9609260559082, 618.1852798461914)"><path d="M 0,8.888292053342576 a 34.47916603088379,8.888292053342576 0,0,0 68.95833206176758 0 a 34.47916603088379,8.888292053342576 0,0,0 -68.95833206176758 0 l 0,48.888292053342575 a 34.47916603088379,8.888292053342576 0,0,0 68.95833206176758 0 l 0,-48.888292053342575" transform="translate(-34.47916603088379,-33.332438080013866)"></path><g class="label" style="" transform="translate(-26.97916603088379, -12.5)"><foreignObject width="53.95833206176758" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>tomcat</span></div></foreignObject></g></g><g class="node default vPod" id="flowchart-TM3-166" label-offset-y="8.888292053342576" transform="translate(832.9609260559082, 734.8501510620117)"><path d="M 0,8.888292053342576 a 34.47916603088379,8.888292053342576 0,0,0 68.95833206176758 0 a 34.47916603088379,8.888292053342576 0,0,0 -68.95833206176758 0 l 0,48.888292053342575 a 34.47916603088379,8.888292053342576 0,0,0 68.95833206176758 0 l 0,-48.888292053342575" transform="translate(-34.47916603088379,-33.332438080013866)"></path><g class="label" style="" transform="translate(-26.97916603088379, -12.5)"><foreignObject width="53.95833206176758" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>tomcat</span></div></foreignObject></g></g><g class="node default NFS" id="flowchart-NFS-177" transform="translate(1001.6848831176758, 424.31814193725586)"><polygon points="10,0 108.48957824707031,0 118.48957824707031,-20 108.48957824707031,-40 10,-40 0,-20" class="label-container" transform="translate(-59.244789123535156,20)"></polygon><g class="label" style="" transform="translate(-41.744789123535156, -12.5)"><foreignObject width="83.48957824707031" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>NFS Server</span></div></foreignObject></g></g><g class="node default User" id="flowchart-U-178" transform="translate(37.56380081176758, 432.46629333496094)"><circle rx="0" ry="0" r="29.563800811767578" width="59.127601623535156" height="40"></circle><g class="label" style="" transform="translate(-22.063800811767578, -12.5)"><foreignObject width="44.127601623535156" height="25"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; white-space: nowrap;"><span>Client</span></div></foreignObject></g></g></g></g></g></svg></div><p>&nbsp;</p></div></div>
</body>
</html>